]> git.sesse.net Git - ffmpeg/commitdiff
vcodec/apedec: Fix integer overflow in filter_3800()
authorMichael Niedermayer <michael@niedermayer.cc>
Sat, 17 Aug 2019 22:36:17 +0000 (00:36 +0200)
committerMichael Niedermayer <michael@niedermayer.cc>
Mon, 2 Sep 2019 19:37:18 +0000 (21:37 +0200)
Fixes: signed integer overflow: 2021654528 + 2032575680 cannot be represented in type 'int'
Fixes: 16270/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_APE_fuzzer-5732438816325632
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavcodec/apedec.c

index 5d82ff53ff044814e0b435469de04c566a69c38e..490b11b94e0b1666f18248b2b247c874fed6e0bc 100644 (file)
@@ -842,7 +842,7 @@ static av_always_inline int filter_fast_3320(APEPredictor *p,
 }
 
 static av_always_inline int filter_3800(APEPredictor *p,
-                                        const int decoded, const int filter,
+                                        const unsigned decoded, const int filter,
                                         const int delayA,  const int delayB,
                                         const int start,   const int shift)
 {