mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-28 10:22:10 +00:00
avcodec/takdsp: Fix negative shift in decorrelate_sf()
Fixes: left shift of negative value -4 Fixes: 25723/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_TAK_fuzzer-6250580752990208 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
2ad9c95c26
commit
4f54f53003
@ -65,7 +65,7 @@ static void decorrelate_sf(int32_t *p1, int32_t *p2, int length, int dshift, int
|
||||
for (i = 0; i < length; i++) {
|
||||
int32_t a = p1[i];
|
||||
int32_t b = p2[i];
|
||||
b = dfactor * (b >> dshift) + 128 >> 8 << dshift;
|
||||
b = (unsigned)(dfactor * (b >> dshift) + 128 >> 8) << dshift;
|
||||
p1[i] = b - a;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user