Commit 0f34c078 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/pictordec: runtime error: left shift of 15 by 28 places cannot be represented in type 'int'

Fixes: 898/clusterfuzz-testcase-6149765467209728

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpegSigned-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 3182e19c
...@@ -62,7 +62,7 @@ static void picmemset(PicContext *s, AVFrame *frame, unsigned value, int run, ...@@ -62,7 +62,7 @@ static void picmemset(PicContext *s, AVFrame *frame, unsigned value, int run,
{ {
uint8_t *d; uint8_t *d;
int shift = *plane * bits_per_plane; int shift = *plane * bits_per_plane;
unsigned mask = ((1 << bits_per_plane) - 1) << shift; unsigned mask = ((1U << bits_per_plane) - 1) << shift;
value <<= shift; value <<= shift;
while (run > 0) { while (run > 0) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment