ffmpeg | branch: master | Peter Ross <pr...@xvid.org> | Sat Jun  8 18:39:40 
2024 +1000| [66124bc36887676c9e25410925063eaecefd37d8] | committer: Peter Ross

avcodec/mm: don't fail if x offset exceeds frame width

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=66124bc36887676c9e25410925063eaecefd37d8
---

 libavcodec/mmvideo.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/mmvideo.c b/libavcodec/mmvideo.c
index 933d895f96..d339967702 100644
--- a/libavcodec/mmvideo.c
+++ b/libavcodec/mmvideo.c
@@ -161,7 +161,7 @@ static int mm_decode_inter(MmContext * s, int half_horiz, 
int half_vert)
             for(j=0; j<8; j++) {
                 int replace = (replace_array >> (7-j)) & 1;
                 if (x + half_horiz >= s->avctx->width)
-                    return AVERROR_INVALIDDATA;
+                    break;
                 if (replace) {
                     int color = bytestream2_get_byte(&data_ptr);
                     s->frame->data[0][y*s->frame->linesize[0] + x] = color;

_______________________________________________
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".

Reply via email to