You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-10 06:10:52 +02:00
pthread: unref already decoded frames when flushing the decoder
Signed-off-by: Anton Khirnov <anton@khirnov.net>
This commit is contained in:
committed by
Anton Khirnov
parent
4e70d66ded
commit
c71c80f53b
@@ -890,6 +890,7 @@ void ff_thread_flush(AVCodecContext *avctx)
|
|||||||
PerThreadContext *p = &fctx->threads[i];
|
PerThreadContext *p = &fctx->threads[i];
|
||||||
// Make sure decode flush calls with size=0 won't return old frames
|
// Make sure decode flush calls with size=0 won't return old frames
|
||||||
p->got_frame = 0;
|
p->got_frame = 0;
|
||||||
|
av_frame_unref(&p->frame);
|
||||||
|
|
||||||
release_delayed_buffers(p);
|
release_delayed_buffers(p);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user