]> git.nihav.org Git - nihav.git/commitdiff
fix an error in AVI demuxer
authorKostya Shishkov <kostya.shishkov@gmail.com>
Sat, 29 Jul 2017 13:18:12 +0000 (15:18 +0200)
committerKostya Shishkov <kostya.shishkov@gmail.com>
Sun, 30 Jul 2017 11:02:07 +0000 (13:02 +0200)
src/demuxers/avi.rs

index 4be5217d2cffbf59839947d73aecefec84d595b5..c00df25ad8682626d4ebdfcb94377f3f934590bd 100644 (file)
@@ -88,6 +88,7 @@ impl<'a> Demux<'a> for AVIDemuxer<'a> {
             if mktag!(tag) == mktag!(b"JUNK") {
                 self.movi_size -= size + 8;
                 self.src.read_skip(size)?;
+                if self.movi_size == 0 { return Err(EOF); }
                 continue;
             }
             if mktag!(tag) == mktag!(b"LIST") {