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 b898fd04a5c1c8bf5839c3bc4eb3c5ab8a4bde70
Author:     Michael Niedermayer <[email protected]>
AuthorDate: Wed Sep 30 20:04:28 2026 +0000
Commit:     Michael Niedermayer <[email protected]>
CommitDate: Sun Nov 15 02:19:35 2026 +0100

    avcodec/vp56: Roll back dimensions when resizing fails
    
    The VP5/VP6 headers install new dimensions before vp56_size_changed() 
allocates the arrays for them.  If resizing fails, leave the dimensions cleared 
so following frames cannot use the missing arrays, and preserve the allocation 
error for the caller.
    
    Fixes: 24187
    
    Assisted-by: Fairy
    (cherry picked from commit 192118f17978b8ca11eadef2f7715395a2b1d413)
    Signed-off-by: Michael Niedermayer <[email protected]>
---
 libavcodec/vp56.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/libavcodec/vp56.c b/libavcodec/vp56.c
index 0d13d7a276..f740b53915 100644
--- a/libavcodec/vp56.c
+++ b/libavcodec/vp56.c
@@ -654,9 +654,11 @@ int ff_vp56_decode_frame(AVCodecContext *avctx, AVFrame 
*rframe,
     }
 
     if (res == VP56_SIZE_CHANGE) {
-        if (vp56_size_changed(s)) {
+        ret = vp56_size_changed(s);
+        if (ret < 0) {
             av_frame_unref(p);
-            return AVERROR_INVALIDDATA;
+            ff_set_dimensions(avctx, 0, 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