Commit e36aaeca authored by Michael Niedermayer's avatar Michael Niedermayer

avfilter/vf_colormatrix: fix memleak on error

Fixes CID1197065
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 5027f397
...@@ -353,6 +353,7 @@ static int filter_frame(AVFilterLink *link, AVFrame *in) ...@@ -353,6 +353,7 @@ static int filter_frame(AVFilterLink *link, AVFrame *in)
case AVCOL_SPC_BT470BG : source = COLOR_MODE_BT601 ; break; case AVCOL_SPC_BT470BG : source = COLOR_MODE_BT601 ; break;
default : default :
av_log(ctx, AV_LOG_ERROR, "Input frame does not specify a supported colorspace, and none has been specified as source either\n"); av_log(ctx, AV_LOG_ERROR, "Input frame does not specify a supported colorspace, and none has been specified as source either\n");
av_frame_free(&out);
return AVERROR(EINVAL); return AVERROR(EINVAL);
} }
color->mode = source * 4 + color->dest; color->mode = source * 4 + color->dest;
......
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