From 086566a557eedc0cf70851b95f1cd7d691d3e41f Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Fri, 1 Feb 2013 03:56:51 +0100 Subject: [PATCH] dict: fix memleak Signed-off-by: Michael Niedermayer --- libavutil/dict.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libavutil/dict.c b/libavutil/dict.c index 23816e8f55..967c9e2fff 100644 --- a/libavutil/dict.c +++ b/libavutil/dict.c @@ -98,6 +98,7 @@ int av_dict_set(AVDictionary **pm, const char *key, const char *value, int flags if (!newval) return AVERROR(ENOMEM); av_strlcat(newval, oldval, len); + av_freep(&oldval); av_strlcat(newval, value, len); m->elems[m->count].value = newval; } else