[FFmpeg-devel] [PATCH] ffplay: fix memleak in audio_thread
Marton Balint
cus at passwd.hu
Fri Sep 2 23:43:34 EEST 2016
On Fri, 2 Sep 2016, Steven Liu wrote:
> ffplay: fix memleak in audio_thread
>
> Signed-off-by: LiuQi <liuqi at gosun.com>
> ---
> ffplay.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/ffplay.c b/ffplay.c
> index adbe9cb..d7f7200 100644
> --- a/ffplay.c
> +++ b/ffplay.c
> @@ -2127,7 +2127,7 @@ static int audio_thread(void *arg)
>
> av_frame_move_ref(af->frame, frame);
> frame_queue_push(&is->sampq);
> -
> + av_frame_unref(frame);
Why is this a mem leak? The av_frame_move_ref call should clear
everything in frame, if that is not the case, then I think the
bug is deeper within the API.
Regards,
Marton
More information about the ffmpeg-devel
mailing list