aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2017-05-10 01:18:36 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2017-05-10 01:19:03 +0200
commit2bd8eb05d21b582d627a93852b59cb3cfc305dae (patch)
tree75acad5ba1e7aa87c697efd310eaef3443052ec3 /libavcodec
parented3c9b5b0dd5abb545c48e930e1c32c187b0776a (diff)
downloadffmpeg-2bd8eb05d21b582d627a93852b59cb3cfc305dae.tar.gz
avcodec/texturedsp: Fix runtime error: left shift of 218 by 24 places cannot be represented in type 'int'
Fixes: 1428/clusterfuzz-testcase-minimized-5263281793007616 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')
-rw-r--r--libavcodec/texturedsp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/texturedsp.c b/libavcodec/texturedsp.c
index 6049c96791..49e97c91ae 100644
--- a/libavcodec/texturedsp.c
+++ b/libavcodec/texturedsp.c
@@ -291,7 +291,7 @@ static inline void dxt5_block_internal(uint8_t *dst, ptrdiff_t stride,
}
}
}
- pixel = colors[code & 3] | (alpha << 24);
+ pixel = colors[code & 3] | ((unsigned)alpha << 24);
code >>= 2;
AV_WL32(dst + x * 4, pixel);
}