You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
avutil/integer: Fix integer overflow in av_mul_i()
Found-by: fate Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
@@ -74,7 +74,7 @@ AVInteger av_mul_i(AVInteger a, AVInteger b){
|
|||||||
|
|
||||||
if(a.v[i])
|
if(a.v[i])
|
||||||
for(j=i; j<AV_INTEGER_SIZE && j-i<=nb; j++){
|
for(j=i; j<AV_INTEGER_SIZE && j-i<=nb; j++){
|
||||||
carry= (carry>>16) + out.v[j] + a.v[i]*b.v[j-i];
|
carry= (carry>>16) + out.v[j] + a.v[i]*(unsigned)b.v[j-i];
|
||||||
out.v[j]= carry;
|
out.v[j]= carry;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user