Commit bce362d3 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/wavpack: Fix runtime error: left shift of negative value -1

Fixes: 1807/clusterfuzz-testcase-minimized-6258676199325696

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpegSigned-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 89325417
...@@ -310,7 +310,7 @@ static float wv_get_value_float(WavpackFrameContext *s, uint32_t *crc, int S) ...@@ -310,7 +310,7 @@ static float wv_get_value_float(WavpackFrameContext *s, uint32_t *crc, int S)
} }
if (S) { if (S) {
S <<= s->float_shift; S *= 1 << s->float_shift;
sign = S < 0; sign = S < 0;
if (sign) if (sign)
S = -S; S = -S;
......
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