summaryrefslogtreecommitdiff
path: root/libavformat/wavdec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2020-11-09 20:53:27 +0100
committerMichael Niedermayer <michael@niedermayer.cc>2021-01-03 01:16:25 +0100
commitf26b5acfc03375c96e593197a8145ada1b63b1fd (patch)
tree9a2e70fa038ea170cf231ccce2a8ec296d4acd11 /libavformat/wavdec.c
parent32d0561891e1a78f9bd18ad667ca526ab1600a06 (diff)
avformat/wavdec: Avoid zeroing written to array
Fixes: OOM Fixes: 26934/clusterfuzz-testcase-minimized-ffmpeg_dem_W64_fuzzer-5996784213819392 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavformat/wavdec.c')
-rw-r--r--libavformat/wavdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/wavdec.c b/libavformat/wavdec.c
index 35c5e442a8..3da4150f05 100644
--- a/libavformat/wavdec.c
+++ b/libavformat/wavdec.c
@@ -917,7 +917,7 @@ static int w64_read_header(AVFormatContext *s)
if (chunk_size == UINT32_MAX || (filesize >= 0 && chunk_size > filesize))
return AVERROR_INVALIDDATA;
- value = av_mallocz(chunk_size + 1);
+ value = av_malloc(chunk_size + 1);
if (!value)
return AVERROR(ENOMEM);