Commit 62929f40 authored by Andreas Rheinhardt's avatar Andreas Rheinhardt

fftools/ffmpeg_filter: Fix leak on error

Do this by attaching the FilterGraph directly to more permanent
storage from which it will be automatically freed.
Fixes Coverity issue #1596533.
Signed-off-by: 's avatarAndreas Rheinhardt <andreas.rheinhardt@outlook.com>
parent b50c5d02
......@@ -1198,10 +1198,10 @@ int init_simple_filtergraph(InputStream *ist, OutputStream *ost,
FilterGraphPriv *fgp;
int ret;
ret = fg_create(&fg, graph_desc, sch);
ret = fg_create(&ost->fg_simple, graph_desc, sch);
if (ret < 0)
return ret;
ost->fg_simple = fg;
fg = ost->fg_simple;
fgp = fgp_from_fg(fg);
fgp->is_simple = 1;
......
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