Message ID | 20241105022325.81909-1-michael@niedermayer.cc |
---|---|
State | New |
Headers | show |
Series | [FFmpeg-devel] avcodec/jpegxl_parser: clear window | expand |
Context | Check | Description |
---|---|---|
yinshiyou/make_loongarch64 | success | Make finished |
yinshiyou/make_fate_loongarch64 | success | Make fate finished |
diff --git a/libavcodec/jpegxl_parser.c b/libavcodec/jpegxl_parser.c index 8c45e1a1b73..179ca1170bd 100644 --- a/libavcodec/jpegxl_parser.c +++ b/libavcodec/jpegxl_parser.c @@ -847,7 +847,7 @@ static int read_distribution_bundle(GetBitContext *gb, JXLEntropyDecoder *dec, } if (bundle->lz77_enabled && !dec->window) { - dec->window = av_malloc_array(1 << 20, sizeof(uint32_t)); + dec->window = calloc(1 << 20, sizeof(uint32_t)); if (!dec->window) return AVERROR(ENOMEM); }
Fixes: Use of uninitialised value of size 8 Fixes: 368725676/clusterfuzz-testcase-minimized-fuzzer_protocol_file-6022251122589696-cut Fixes: 42537758/clusterfuzz-testcase-minimized-fuzzer_protocol_file-5818969469026304-cut Found-by: ossfuzz Reported-by: Kacper Michajlow Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> --- libavcodec/jpegxl_parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)