summaryrefslogtreecommitdiff
path: root/libavfilter/vf_gradfun.c
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2013-03-18 21:31:54 +0100
committerAnton Khirnov <anton@khirnov.net>2013-05-17 07:42:39 +0200
commit87c31cfd7a2cd7893c589b4f25d6d45b196e20c1 (patch)
tree2aff76ba44c5ffe5fc95065c4b98ae01963a7cec /libavfilter/vf_gradfun.c
parentb06848f4deccb998f019eadc9a72e595bb5db4a9 (diff)
vf_gradfun: make config_props work properly when called multiple times.
Diffstat (limited to 'libavfilter/vf_gradfun.c')
-rw-r--r--libavfilter/vf_gradfun.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavfilter/vf_gradfun.c b/libavfilter/vf_gradfun.c
index 402e3b5af3..8ed706d149 100644
--- a/libavfilter/vf_gradfun.c
+++ b/libavfilter/vf_gradfun.c
@@ -166,6 +166,7 @@ static int config_input(AVFilterLink *inlink)
int hsub = desc->log2_chroma_w;
int vsub = desc->log2_chroma_h;
+ av_freep(&s->buf);
s->buf = av_mallocz((FFALIGN(inlink->w, 16) * (s->radius + 1) / 2 + 32) * sizeof(uint16_t));
if (!s->buf)
return AVERROR(ENOMEM);