Do not drop packets with no valid ->pos set as e.g. DV-in-AVI produces.
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>
Sat, 30 Apr 2011 09:49:49 +0000 (11:49 +0200)
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>
Sat, 30 Apr 2011 21:06:04 +0000 (23:06 +0200)
Fixes ticket #140.

libavformat/avidec.c

index 6a5d1e7..c497b9a 100644 (file)
@@ -1016,7 +1016,7 @@ resync:
             ast->packet_size= 0;
         }
 
-        if(!avi->non_interleaved && ast->seek_pos > pkt->pos){
+        if(!avi->non_interleaved && pkt->pos >= 0 && ast->seek_pos > pkt->pos){
             av_free_packet(pkt);
             goto resync;
         }