avcodec/mscc: avcodec/mscc: allocate the RLE buffer with av_mallocz to avoid heap disclosure

Fixes: use of uninitialized memory
Fixes: poc.avi
Fixes: ROv3JuiJJEdT
Found-by: Umar Pathan (Umar0x)
This commit is contained in:
Umar Pathan authored and michaelni committed 2026-09-28 03:48:31 +00:00
1 parent be21a3957c
commit 263a85e2a2
1 file changed
+1 -1
+1 -1
View File
@@ -233,7 +233,7 @@ static av_cold int decode_init(AVCodecContext *avctx)
return AVERROR(ENOMEM);
s->uncomp_size = avctx->height * stride;
if (!(s->uncomp_buf = av_malloc(s->uncomp_size)))
if (!(s->uncomp_buf = av_mallocz(s->uncomp_size)))
return AVERROR(ENOMEM);
return ff_inflate_init(&s->zstream, avctx);