summaryrefslogtreecommitdiff
path: root/libavformat
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-12-22 11:51:55 +0100
committerMichael Niedermayer <michaelni@gmx.at>2014-12-22 12:03:35 +0100
commitfd3e7447c83b7a652b66e3a4334e4335d232d77e (patch)
treee1a584cab740b4845e203213f512803d76fc4619 /libavformat
parent5dfae3f40a73c69cbca2b7d8d31cbfc6920aa701 (diff)
avformat/riffdec: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/riffdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/riffdec.c b/libavformat/riffdec.c
index edaf146d1c..f44df1e672 100644
--- a/libavformat/riffdec.c
+++ b/libavformat/riffdec.c
@@ -132,7 +132,7 @@ int ff_get_wav_header(AVIOContext *pb, AVCodecContext *codec, int size, int big_
size -= 22;
}
if (cbSize > 0) {
- av_free(codec->extradata);
+ av_freep(&codec->extradata);
if (ff_get_extradata(codec, pb, cbSize) < 0)
return AVERROR(ENOMEM);
size -= cbSize;