summaryrefslogtreecommitdiff
path: root/libavfilter/avfilter.c
diff options
context:
space:
mode:
authorNicolas George <george@nsup.org>2016-12-22 10:26:03 +0100
committerNicolas George <george@nsup.org>2016-12-22 10:35:48 +0100
commitff8b17c998dca3f0026466638430ed183426bdde (patch)
tree434697debc9bc0a1f775e07217ab5a6869f99c7d /libavfilter/avfilter.c
parent314269118161ed7735a905332ccf847d1ec696a2 (diff)
lavfi: take_samples: free frames after taking all samples.
Diffstat (limited to 'libavfilter/avfilter.c')
-rw-r--r--libavfilter/avfilter.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c
index c2a84136b3..0020ee163a 100644
--- a/libavfilter/avfilter.c
+++ b/libavfilter/avfilter.c
@@ -1288,6 +1288,7 @@ static int take_samples(AVFilterLink *link, unsigned min, unsigned max,
av_samples_copy(buf->extended_data, frame->extended_data, p, 0,
frame->nb_samples, link->channels, link->format);
p += frame->nb_samples;
+ av_frame_free(&frame);
}
if (p < nb_samples) {
unsigned n = nb_samples - p;