[FFmpeg-cvslog] avformat/mxfdec: free duplicated utf16 strings
Michael Niedermayer
git at videolan.org
Sun Jun 14 22:24:02 EEST 2020
ffmpeg | branch: master | Michael Niedermayer <michael at niedermayer.cc> | Sun Jun 14 19:45:05 2020 +0200| [0aa2768cb275bda9e9e1331ed95adc7cd686eafe] | committer: Michael Niedermayer
avformat/mxfdec: free duplicated utf16 strings
Fixes: memleak
Fixes: 23415/clusterfuzz-testcase-minimized-ffmpeg_DEMUXER_fuzzer-5124814510751744
Suggested-by: Marton Balint <cus at passwd.hu>
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0aa2768cb275bda9e9e1331ed95adc7cd686eafe
---
libavformat/mxfdec.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/libavformat/mxfdec.c b/libavformat/mxfdec.c
index a60bdfeade..90546d42b3 100644
--- a/libavformat/mxfdec.c
+++ b/libavformat/mxfdec.c
@@ -867,6 +867,7 @@ static inline int mxf_read_utf16_string(AVIOContext *pb, int size, char** str, i
return AVERROR(EINVAL);
buf_size = size + size / 2 + 1;
+ av_free(*str);
*str = av_malloc(buf_size);
if (!*str)
return AVERROR(ENOMEM);
More information about the ffmpeg-cvslog
mailing list