ffplay: drop remaining frames in current audio avpacket when seeking
authorMarton Balint <cus@passwd.hu>
Sat, 16 Feb 2013 19:53:07 +0000 (20:53 +0100)
committerMarton Balint <cus@passwd.hu>
Wed, 27 Feb 2013 20:34:12 +0000 (21:34 +0100)
Fixes ticket #1928.

Signed-off-by: Marton Balint <cus@passwd.hu>
ffplay.c

index d5a9dc3..ed53023 100644 (file)
--- a/ffplay.c
+++ b/ffplay.c
@@ -2090,6 +2090,9 @@ static int audio_decode_frame(VideoState *is)
             } else
                 avcodec_get_frame_defaults(is->frame);
 
+            if (is->audioq.serial != is->audio_pkt_temp_serial)
+                break;
+
             if (is->paused)
                 return -1;