Commit 0d65e0f8 authored by Stefano Sabatini's avatar Stefano Sabatini

cmdutils: reset *picref_ptr to NULL in get_filtered_frame()

Avoid the presence of an invalid pointer, fix a crash in case of
get_filtered_frame() failure.
parent 32881039
...@@ -908,6 +908,7 @@ int get_filtered_video_frame(AVFilterContext *ctx, AVFrame *frame, ...@@ -908,6 +908,7 @@ int get_filtered_video_frame(AVFilterContext *ctx, AVFrame *frame,
{ {
int ret; int ret;
AVFilterBufferRef *picref; AVFilterBufferRef *picref;
*picref_ptr = NULL;
if ((ret = avfilter_request_frame(ctx->inputs[0])) < 0) if ((ret = avfilter_request_frame(ctx->inputs[0])) < 0)
return ret; return ret;
......
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