Merge "Fix overflow in RD error calculation code." into experimental
This commit is contained in:
commit
842c573e04
@ -602,7 +602,7 @@ static int block_error(int16_t *coeff, int16_t *dqcoeff,
|
||||
|
||||
for (i = 0; i < block_size; i++) {
|
||||
int this_diff = coeff[i] - dqcoeff[i];
|
||||
error += this_diff * this_diff;
|
||||
error += (unsigned)this_diff * this_diff;
|
||||
}
|
||||
error >>= shift;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user