diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2016-12-04 00:11:17 +0100 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2016-12-04 00:12:06 +0100 |
commit | 1f5630af51f24d79053b6bef5b8b3ba93d637306 (patch) | |
tree | 2c6f3795016da17a656eb8bf5abc7891d8967a25 /libavcodec/flacdec.c | |
parent | c72fa432349881d5a445cd110abf698cc94d490d (diff) | |
download | ffmpeg-1f5630af51f24d79053b6bef5b8b3ba93d637306.tar.gz |
avcodec/flacdec: Fix undefined shift in decode_subframe()
Fixes undefined behavior
Fixes: 639961-media
Found-by: Matt Wolenetz <wolenetz@google.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/flacdec.c')
-rw-r--r-- | libavcodec/flacdec.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/flacdec.c b/libavcodec/flacdec.c index d1beb4e15e..af81115ff8 100644 --- a/libavcodec/flacdec.c +++ b/libavcodec/flacdec.c @@ -452,7 +452,7 @@ static inline int decode_subframe(FLACContext *s, int channel) if (wasted) { int i; for (i = 0; i < s->blocksize; i++) - decoded[i] <<= wasted; + decoded[i] = (unsigned)decoded[i] << wasted; } return 0; |