This is an automated email from the git hooks/post-receive script.

Git pushed a commit to branch release/9.1
in repository ffmpeg.

commit d304bb85dde788541880c2236e116c48f41e3bb1
Author:     Michael Niedermayer <[email protected]>
AuthorDate: Wed Nov 11 04:49:02 2026 +0100
Commit:     Michael Niedermayer <[email protected]>
CommitDate: Sun Nov 15 21:19:57 2026 +0100

    avcodec/vvc/dec: limit the slices of a picture to VVC_MAX_SLICES
    
    Fixes: excessive memory allocation
    Fixes: yGiQvHbsEdXd
    
    Found during the review of https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/25491
    
    (cherry picked from commit aae470474ffe2580ed83cc0b805903b826091b5f)
    Signed-off-by: Michael Niedermayer <[email protected]>
---
 libavcodec/vvc/dec.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/libavcodec/vvc/dec.c b/libavcodec/vvc/dec.c
index f69fa99c6d..b2dcc853ac 100644
--- a/libavcodec/vvc/dec.c
+++ b/libavcodec/vvc/dec.c
@@ -953,6 +953,9 @@ static int decode_slice(VVCContext *s, VVCFrameContext *fc, 
AVBufferRef *buf_ref
     SliceContext *sc;
     const int is_first_slice = !fc->nb_slices;
 
+    if (fc->nb_slices >= VVC_MAX_SLICES)
+        return AVERROR_INVALIDDATA;
+
     ret = slices_realloc(fc);
     if (ret < 0)
         return ret;

-- 
To stop receiving notification emails like this one, please contact
[email protected].
_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to