Commit 2051b401 authored by Ivan Efimov's avatar Ivan Efimov Committed by Michael Niedermayer

avfilter/drawtext: fix frame mem leak

Signed-off-by: 's avatarIvan Efimov <ioefimov@gmail.com>
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 013498ba
......@@ -1275,12 +1275,16 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *frame)
int ret;
if (s->reload) {
if ((ret = load_textfile(ctx)) < 0)
if ((ret = load_textfile(ctx)) < 0) {
av_frame_free(&frame);
return ret;
}
#if CONFIG_LIBFRIBIDI
if (s->text_shaping)
if ((ret = shape_text(ctx)) < 0)
if ((ret = shape_text(ctx)) < 0) {
av_frame_free(&frame);
return ret;
}
#endif
}
......
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