Skip to content
Snippets Groups Projects
Commit 35f3df0d authored by Michael Niedermayer's avatar Michael Niedermayer
Browse files

avutil/softfloat: Fix multiple runtime error: left shift of negative value -8

Fixes: 1352/clusterfuzz-testcase-minimized-5757565017260032

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg


Signed-off-by: default avatarMichael Niedermayer <michael@niedermayer.cc>
parent 12dea8a5
No related branches found
No related tags found
No related merge requests found
......@@ -234,12 +234,12 @@ static av_unused void av_sincos_sf(int a, int *s, int *c)
int st, ct;
idx = a >> 26;
sign = (idx << 27) >> 31;
sign = (int32_t)((unsigned)idx << 27) >> 31;
cv = av_costbl_1_sf[idx & 0xf];
cv = (cv ^ sign) - sign;
idx -= 8;
sign = (idx << 27) >> 31;
sign = (int32_t)((unsigned)idx << 27) >> 31;
sv = av_costbl_1_sf[idx & 0xf];
sv = (sv ^ sign) - sign;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment