summaryrefslogtreecommitdiff
path: root/libavfilter/f_select.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-08-11 22:02:44 +0200
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-08-22 16:14:07 +0200
commit64133506f7894a93bbd143b54224a6e85cdb59fe (patch)
tree73076f2ff6cc332755211d27b5e304580bf67514 /libavfilter/f_select.c
parentf6c6a51d988763fe92961ff483c6d5eb98055f38 (diff)
downloadffmpeg-64133506f7894a93bbd143b54224a6e85cdb59fe.tar.gz
avfilter/f_select: Free outpads' names generically
Reviewed-by: Nicolas George <george@nsup.org> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavfilter/f_select.c')
-rw-r--r--libavfilter/f_select.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/libavfilter/f_select.c b/libavfilter/f_select.c
index fad54ab16a..187e98a1a7 100644
--- a/libavfilter/f_select.c
+++ b/libavfilter/f_select.c
@@ -192,10 +192,8 @@ static av_cold int init(AVFilterContext *ctx)
return AVERROR(ENOMEM);
pad.type = ctx->filter->inputs[0].type;
pad.request_frame = request_frame;
- if ((ret = ff_append_outpad(ctx, &pad)) < 0) {
- av_freep(&pad.name);
+ if ((ret = ff_append_outpad_free_name(ctx, &pad)) < 0)
return ret;
- }
}
return 0;
@@ -432,14 +430,10 @@ static int request_frame(AVFilterLink *outlink)
static av_cold void uninit(AVFilterContext *ctx)
{
SelectContext *select = ctx->priv;
- int i;
av_expr_free(select->expr);
select->expr = NULL;
- for (i = 0; i < ctx->nb_outputs; i++)
- av_freep(&ctx->output_pads[i].name);
-
if (select->do_scene_detect) {
av_frame_free(&select->prev_picref);
}