Fixed integer oveflow in local__compute_rbps_integerized
Bug: 133002944
Test: Apply cts CL for testFlacEncoders
Test: atest android.media.cts.EncoderTest#testFlacEncoders
Change-Id: I3281c895e9831123c89567535e641ff58c35bcc9
diff --git a/libFLAC/fixed.c b/libFLAC/fixed.c
index ed9f498..2e16251 100644
--- a/libFLAC/fixed.c
+++ b/libFLAC/fixed.c
@@ -87,7 +87,7 @@
bits = FLAC__bitmath_ilog2(err)+1;
if(bits > 16) {
err >>= (bits-16);
- fracbits -= (bits-16);
+ fracbits -= (int)(bits-16);
}
rbps = (FLAC__uint32)err;