mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-08 13:22:53 +02:00
avcodec/vqavideo: use av_mallocz() for decode_buffer()
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7f62eaba897d_595_4D6EFA92.VQA Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
0b1cfc4f28
commit
e6364ea26d
@ -179,7 +179,7 @@ static av_cold int vqa_decode_init(AVCodecContext *avctx)
|
||||
/* allocate decode buffer */
|
||||
s->decode_buffer_size = (s->width / s->vector_width) *
|
||||
(s->height / s->vector_height) * 2;
|
||||
s->decode_buffer = av_malloc(s->decode_buffer_size);
|
||||
s->decode_buffer = av_mallocz(s->decode_buffer_size);
|
||||
if (!s->decode_buffer)
|
||||
goto fail;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user