diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2017-02-24 13:11:43 +0100 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2017-05-20 03:41:32 +0200 |
commit | 5c764f0625b4be5dff5287dcffb9fd74b6b3032d (patch) | |
tree | e8fe63d5e553a5f734d60e2fb41bc71c03c54354 | |
parent | 3b067c9edcc6983971f72603c55941d5aca61215 (diff) | |
download | ffmpeg-5c764f0625b4be5dff5287dcffb9fd74b6b3032d.tar.gz |
avcodec/vp3dsp: Fix multiple signed integer overflow: 46341 * 47523 cannot be represented in type 'int'
Fixes: 664/clusterfuzz-testcase-4917047475568640
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 2b8b7921c55a93049a86cfeb2fda9423d16f8ebe)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r-- | libavcodec/vp3dsp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/vp3dsp.c b/libavcodec/vp3dsp.c index d8a3e0a354..37997431d3 100644 --- a/libavcodec/vp3dsp.c +++ b/libavcodec/vp3dsp.c @@ -41,7 +41,7 @@ #define xC6S2 25080 #define xC7S1 12785 -#define M(a, b) (((a) * (b)) >> 16) +#define M(a, b) ((int)((SUINT)(a) * (b)) >> 16) static av_always_inline void idct(uint8_t *dst, int stride, int16_t *input, int type) |