mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-12-13 10:30:05 +01:00
avcodec/lagarith: Fix runtime error: left shift of negative value -1
Fixes: 1424/clusterfuzz-testcase-minimized-6088327159611392 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
@@ -98,7 +98,7 @@ static uint32_t softfloat_mul(uint32_t x, uint64_t mantissa)
|
|||||||
|
|
||||||
static uint8_t lag_calc_zero_run(int8_t x)
|
static uint8_t lag_calc_zero_run(int8_t x)
|
||||||
{
|
{
|
||||||
return (x << 1) ^ (x >> 7);
|
return (x * 2) ^ (x >> 7);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int lag_decode_prob(GetBitContext *gb, uint32_t *value)
|
static int lag_decode_prob(GetBitContext *gb, uint32_t *value)
|
||||||
|
|||||||
Reference in New Issue
Block a user