Commit fa8919fd4a for ffmpeg
commit fa8919fd4ad74912316f294716486ef24af97a93
Author: Michael Niedermayer <michael@niedermayer.cc>
Date: Wed Nov 11 18:53:22 2026 +0100
avcodec/iff: allocate the plane buffer zeroed
Fixes: use of uninitialized memory
Fixes: FPOEGUObScuK
Fixes: ilbm-vdat-missing.iff
Use of uninitialized memory Replicated through UnModified FFmpeg with MSAN
Found during triage of the security report dLFZWeypJpSK
diff --git a/libavcodec/iff.c b/libavcodec/iff.c
index 329a2d9ce3..71cc8b3c33 100644
--- a/libavcodec/iff.c
+++ b/libavcodec/iff.c
@@ -371,7 +371,7 @@ static av_cold int decode_init(AVCodecContext *avctx)
if ((err = av_image_check_size(avctx->width, avctx->height, 0, avctx)))
return err;
s->planesize = FFALIGN(avctx->width, 16) >> 3; // Align plane size in bits to word-boundary
- s->planebuf = av_malloc(s->planesize * avctx->height + AV_INPUT_BUFFER_PADDING_SIZE);
+ s->planebuf = av_mallocz(s->planesize * avctx->height + AV_INPUT_BUFFER_PADDING_SIZE);
if (!s->planebuf)
return AVERROR(ENOMEM);