Fixes: signed integer overflow: 1 + 2147483647 cannot be represented in type 'int' Fixes: 30877/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MOBICLIP_fuzzer-4775601145774080
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <mich...@niedermayer.cc> --- libavcodec/mobiclip.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavcodec/mobiclip.c b/libavcodec/mobiclip.c index e5c6617325..9392ab947e 100644 --- a/libavcodec/mobiclip.c +++ b/libavcodec/mobiclip.c @@ -1091,8 +1091,8 @@ static int predict_motion(AVCodecContext *avctx, sidx += 6; if (index > 0) { - mv.x = mv.x + get_se_golomb(gb); - mv.y = mv.y + get_se_golomb(gb); + mv.x = mv.x + (unsigned)get_se_golomb(gb); + mv.y = mv.y + (unsigned)get_se_golomb(gb); } if (mv.x >= INT_MAX || mv.y >= INT_MAX) return AVERROR_INVALIDDATA; -- 2.17.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".