diff options
author | Justin Ruggles <justin.ruggles@gmail.com> | 2012-02-04 17:32:26 -0500 |
---|---|---|
committer | Justin Ruggles <justin.ruggles@gmail.com> | 2012-02-06 13:22:01 -0500 |
commit | ec1f3cab2061531d9b200213afeb5614f880d5d4 (patch) | |
tree | bf3e7da050d92e932e9f51b01b90e0b8db4f5ec4 /avplay.c | |
parent | f1c3d4a68a743c1b274dc764e54e2df276a7c774 (diff) | |
download | ffmpeg-ec1f3cab2061531d9b200213afeb5614f880d5d4.tar.gz |
avplay: reset decoder flush state when seeking
Fixes seeking after decoder has already been flushed for codecs using
CODEC_CAP_DELAY.
Diffstat (limited to 'avplay.c')
-rw-r--r-- | avplay.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -2114,8 +2114,10 @@ static int audio_decode_frame(VideoState *is, double *pts_ptr) if ((new_packet = packet_queue_get(&is->audioq, pkt, 1)) < 0) return -1; - if (pkt->data == flush_pkt.data) + if (pkt->data == flush_pkt.data) { avcodec_flush_buffers(dec); + flush_complete = 0; + } *pkt_temp = *pkt; |