Commit 304eaa63 authored by Jun Zhao's avatar Jun Zhao Committed by Nicolas George

lavfi/buffersrc: Remove redundant free after ff_filter_frame() failure

ff_filter_frame() always frees the frame in case of error, so we don't
need to free the frame after ff_filter_frame() fails.

Fix CID 1457230.
Signed-off-by: 's avatarJun Zhao <barryjzhao@tencent.com>
parent 38986535
......@@ -240,10 +240,8 @@ static int av_buffersrc_add_frame_internal(AVFilterContext *ctx,
}
ret = ff_filter_frame(ctx->outputs[0], copy);
if (ret < 0) {
av_frame_free(&copy);
if (ret < 0)
return ret;
}
if ((flags & AV_BUFFERSRC_FLAG_PUSH)) {
ret = push_frame(ctx->graph);
......
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