diff options
author | Paul B Mahol <onemda@gmail.com> | 2016-09-09 12:58:18 +0300 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2016-09-09 12:58:18 +0300 |
commit | 653ca058079ccf65f487abd5f30f479903ec82ac (patch) | |
tree | 148ffdf809917beadaaed02e45145f0884a0e750 /libavfilter | |
parent | ac3f9be330f39e18edb4d720b461b01c8da10684 (diff) |
avfilter/vf_weave: do not leak unused frame
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Diffstat (limited to 'libavfilter')
-rw-r--r-- | libavfilter/vf_weave.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libavfilter/vf_weave.c b/libavfilter/vf_weave.c index 2f0784e703..a5fc1b7403 100644 --- a/libavfilter/vf_weave.c +++ b/libavfilter/vf_weave.c @@ -115,6 +115,13 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in) return ff_filter_frame(outlink, out); } +static av_cold void uninit(AVFilterContext *ctx) +{ + WeaveContext *s = ctx->priv; + + av_frame_free(&s->prev); +} + static const AVFilterPad weave_inputs[] = { { .name = "default", @@ -138,6 +145,7 @@ AVFilter ff_vf_weave = { .description = NULL_IF_CONFIG_SMALL("Weave input video fields into frames."), .priv_size = sizeof(WeaveContext), .priv_class = &weave_class, + .uninit = uninit, .inputs = weave_inputs, .outputs = weave_outputs, }; |