mirror of https://github.com/mstorsjo/fdk-aac.git
Avoid unsigned integer overflow in transportDec_InBandConfig() and transportDec_ReadAccessUnit().
Bug: 146937857 Test: atest DecoderTestXheAac ; atest DecoderTestAacDrc Change-Id: If2320f3a1ddf6a36c07338100481801a996e455d
This commit is contained in:
parent
9ab63ce151
commit
8caa63f329
|
@ -482,7 +482,8 @@ TRANSPORTDEC_ERROR transportDec_InBandConfig(HANDLE_TRANSPORTDEC hTp,
|
||||||
|
|
||||||
for (int i = 0; i < 2; i++) {
|
for (int i = 0; i < 2; i++) {
|
||||||
if (i > 0) {
|
if (i > 0) {
|
||||||
FDKpushBack(hBs, newConfigLength * 8 - FDKgetValidBits(hBs));
|
FDKpushBack(hBs,
|
||||||
|
(INT)newConfigLength * 8 - (INT)FDKgetValidBits(hBs));
|
||||||
configMode = AC_CM_ALLOC_MEM;
|
configMode = AC_CM_ALLOC_MEM;
|
||||||
}
|
}
|
||||||
/* config transport decoder */
|
/* config transport decoder */
|
||||||
|
@ -1469,7 +1470,7 @@ TRANSPORTDEC_ERROR transportDec_ReadAccessUnit(const HANDLE_TRANSPORTDEC hTp,
|
||||||
|
|
||||||
for (i = 0; i < 2; i++) {
|
for (i = 0; i < 2; i++) {
|
||||||
if (i > 0) {
|
if (i > 0) {
|
||||||
FDKpushBack(hBs, bsStart - FDKgetValidBits(hBs));
|
FDKpushBack(hBs, bsStart - (INT)FDKgetValidBits(hBs));
|
||||||
configMode = AC_CM_ALLOC_MEM;
|
configMode = AC_CM_ALLOC_MEM;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue