goom: fix undefined behaviour of left-shift

Don't left-shift into the sign bit, the result is undefined and potentially
an overflow could flip the sign.
This commit is contained in:
Luis de Bethencourt 2014-04-27 18:29:11 -04:00
parent 5dc2e6bef1
commit 3943c3ec08

View file

@ -731,7 +731,7 @@ generatePrecalCoef (int precalCoef[16][16])
if (!(coefh || coefv)) {
i = 255;
} else {
int i1, i2, i3, i4;
uint i1, i2, i3, i4;
i1 = diffcoeffh * diffcoeffv;
i2 = coefh * diffcoeffv;