aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2017-05-13 23:16:44 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2017-05-14 00:21:50 +0200
commit3ed0d94b827a67b91b727f2a58ed96e66d8ea2d7 (patch)
treed20ded14b725afb32bfd21d89e51ed96562f2455
parent6f8dab7a7bd9fdf00b2c1f1e62bd2aa159f40908 (diff)
downloadffmpeg-3ed0d94b827a67b91b727f2a58ed96e66d8ea2d7.tar.gz
avcodec/svq3: Fix runtime error: signed integer overflow: 169 * 12717677 cannot be represented in type 'int'
Fixes: 1556/clusterfuzz-testcase-minimized-5027865978470400 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 86b1b0d33dd7459f0d9c352c51ee2e374fd6f7fe) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libavcodec/svq3.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/svq3.c b/libavcodec/svq3.c
index c9d4160a1a..4814b80c3a 100644
--- a/libavcodec/svq3.c
+++ b/libavcodec/svq3.c
@@ -263,7 +263,7 @@ static void svq3_add_idct_c(uint8_t *dst, int16_t *block,
int i;
if (dc) {
- dc = 13 * 13 * (dc == 1 ? 1538 * block[0]
+ dc = 13 * 13 * (dc == 1 ? 1538U* block[0]
: qmul * (block[0] >> 3) / 2);
block[0] = 0;
}