PR #22903 opened by michaelni
URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/22903
Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/22903.patch

Signed-off-by: Michael Niedermayer <[email protected]>


>From 851dcac21e39809b72688176f466be3d6b0c86cb Mon Sep 17 00:00:00 2001
From: ASTRA <[email protected]>
Date: Thu, 23 Apr 2026 21:58:27 +0200
Subject: [PATCH] avformat/vividas: use-of-uninitialized-value in keybuffer

Signed-off-by: Michael Niedermayer <[email protected]>
---
 libavformat/vividas.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/libavformat/vividas.c b/libavformat/vividas.c
index 76d65518ba..9617b10c0a 100644
--- a/libavformat/vividas.c
+++ b/libavformat/vividas.c
@@ -589,7 +589,9 @@ static int viv_read_header(AVFormatContext *s)
         block_type = avio_r8(pb);
 
         if (block_type == 22) {
-            avio_read(pb, keybuffer, 187);
+            ret = ffio_read_size(pb, keybuffer, 187);
+            if (ret < 0)
+                return ret;
             b22_key = decode_key(keybuffer);
             b22_size = avio_rl32(pb);
         }
-- 
2.52.0

_______________________________________________
ffmpeg-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to