aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/pictordec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2017-03-13 20:45:07 +0100
committerMichael Niedermayer <michael@niedermayer.cc>2017-03-14 22:48:49 +0100
commit0728d9a281068add5898a8b51cd9c6f3b973ea31 (patch)
treec63c1e1231f5c2f407142a1502437d01cc3fe65e /libavcodec/pictordec.c
parentb2206475b45950954c3af38dc09722c7b217611d (diff)
downloadffmpeg-0728d9a281068add5898a8b51cd9c6f3b973ea31.tar.gz
avcodec/pictordec: Fix runtime error: left shift of 805306368 by 2 places cannot be represented in type 'int'
Fixes: 823/clusterfuzz-testcase-6727060074528768 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/pictordec.c')
-rw-r--r--libavcodec/pictordec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/pictordec.c b/libavcodec/pictordec.c
index 2dbc040b5c..8b075bfd0c 100644
--- a/libavcodec/pictordec.c
+++ b/libavcodec/pictordec.c
@@ -62,7 +62,7 @@ static void picmemset(PicContext *s, AVFrame *frame, unsigned value, int run,
{
uint8_t *d;
int shift = *plane * bits_per_plane;
- int mask = ((1 << bits_per_plane) - 1) << shift;
+ unsigned mask = ((1 << bits_per_plane) - 1) << shift;
value <<= shift;
while (run > 0) {