Commit 004f27f0 authored by Michael Niedermayer's avatar Michael Niedermayer

ffmpeg: Fix avframe memleak

Fixes CID1401674
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 8779ec91
......@@ -2176,8 +2176,10 @@ static int ifilter_send_frame(InputFilter *ifilter, AVFrame *frame)
if (!av_fifo_space(ifilter->frame_queue)) {
ret = av_fifo_realloc2(ifilter->frame_queue, 2 * av_fifo_size(ifilter->frame_queue));
if (ret < 0)
if (ret < 0) {
av_frame_free(&tmp);
return ret;
}
}
av_fifo_generic_write(ifilter->frame_queue, &tmp, sizeof(tmp), NULL);
return 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment