summaryrefslogtreecommitdiff
path: root/decoders/common/sdcard/__init__.py
diff options
context:
space:
mode:
authorGerhard Sittig <gerhard.sittig@gmx.net>2022-10-03 18:29:46 +0200
committerGerhard Sittig <gerhard.sittig@gmx.net>2022-10-03 21:30:52 +0200
commite303fd42917f4e15a06c9da5912344c8566fffb0 (patch)
treefe3d43469b9eb385188cbd3875d2a7fe9c57c1e4 /decoders/common/sdcard/__init__.py
parent27a86cefb655ecdfb8d912a5388fe8768b264ff5 (diff)
downloadlibsigrokdecode-e303fd42917f4e15a06c9da5912344c8566fffb0.tar.gz
libsigrokdecode-e303fd42917f4e15a06c9da5912344c8566fffb0.zip
parallel: flush accumulated data when input data is exhausted
The "parallel" decoder buffers the currently seen data pattern, and defers annotation emission until the end position is known. Which is why the last data pattern would not show up in the decoder's output. See bug #292 and its duplicates for examples and concerns. Catch the EOFError exception, and flush previously accumulated data. It is yet to get determined whether a warning annotation is due. Most probably not for "parallel" which merely visualizes data line states. But other decoders which have the concept of frames shall NOT follow this "parallel" decoder's naive approach, and claim that a frame had completed although its end condition was never seen. Add a developer TODO comment to raise awareness.
Diffstat (limited to 'decoders/common/sdcard/__init__.py')
0 files changed, 0 insertions, 0 deletions