You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The SAM sam_dispatcher_read decodes blocks of SAM records into blocks
of BAM records. As this is (hopefully) reading ahead of the sam_read1
consumer code, when it hits EOF it adds a final NULL block as a
sentinel. This works well and it forces sam_read1 to return EOF too.
However, if we ignore that and call sam_read1 again, it's consumed our
sentinel block and it gets stuck waiting for the next block of BAM
records. We now cache the EOF status and check first.
Note this doesn't impact on iterators as they work at a different
level already and it's the iterator itself which tracks EOF.
Fixessamtools#1855
To re-produce:
This happens when the input is SAM, but not with BAM.
The text was updated successfully, but these errors were encountered: