Merge "Unsigned Integer Overflow in SpatialDecParseSpecificConfigHeader()." am: 0695cff3dd

am: 36b3869e2c

Change-Id: I2a7d3a865dce40cbce0c2b345b8f489a8e4a7e3f
This commit is contained in:
Fraunhofer IIS FDK 2018-11-27 12:47:01 -08:00 committed by android-build-merger
commit 479cc5a6d4
1 changed files with 2 additions and 2 deletions

View File

@ -291,13 +291,13 @@ SACDEC_ERROR SpatialDecParseSpecificConfigHeader(
if (sacHeaderLen == 127) {
sacHeaderLen += FDKreadBits(bitstream, 16);
}
numFillBits = FDKgetValidBits(bitstream);
numFillBits = (INT)FDKgetValidBits(bitstream);
err = SpatialDecParseSpecificConfig(bitstream, pSpatialSpecificConfig,
sacHeaderLen, coreCodec);
numFillBits -=
FDKgetValidBits(bitstream); /* the number of read bits (tmpBits) */
(INT)FDKgetValidBits(bitstream); /* the number of read bits (tmpBits) */
numFillBits = (8 * sacHeaderLen) - numFillBits;
if (numFillBits < 0) {
/* Parsing went wrong */