diff options
author | Jean-Michel Trivi <jmtrivi@google.com> | 2018-12-26 17:06:27 -0800 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2018-12-26 17:06:27 -0800 |
commit | f69ca4c61480acd4248aa4975ef205e1a96eaa3f (patch) | |
tree | 71ab36d4737360d50015d51b6765a8cd74ed5aec /libAACdec/src | |
parent | 232d00017306ad6a8a3fe43487cf61c3e24e0e9b (diff) | |
parent | b471c2c21574ab30b49c4ebf85699a951779700f (diff) | |
download | fdk-aac-f69ca4c61480acd4248aa4975ef205e1a96eaa3f.tar.gz fdk-aac-f69ca4c61480acd4248aa4975ef205e1a96eaa3f.tar.bz2 fdk-aac-f69ca4c61480acd4248aa4975ef205e1a96eaa3f.zip |
Merge "Signed Integer Overflow in E_UTIL_preemph()" am: aea2558c50
am: b471c2c215
Change-Id: Ib6f14a5f7b33ffb8bce1a9b37531c0872eeceb2e
Diffstat (limited to 'libAACdec/src')
-rw-r--r-- | libAACdec/src/channelinfo.h | 2 | ||||
-rw-r--r-- | libAACdec/src/usacdec_fac.cpp | 2 | ||||
-rw-r--r-- | libAACdec/src/usacdec_fac.h | 2 | ||||
-rw-r--r-- | libAACdec/src/usacdec_lpd.cpp | 1 |
4 files changed, 4 insertions, 3 deletions
diff --git a/libAACdec/src/channelinfo.h b/libAACdec/src/channelinfo.h index 45a288f..4523400 100644 --- a/libAACdec/src/channelinfo.h +++ b/libAACdec/src/channelinfo.h @@ -359,7 +359,7 @@ typedef struct { shouldBeUnion { struct { FIXP_DBL fac_data0[LFAC]; - UCHAR fac_data_e[4]; + SCHAR fac_data_e[4]; FIXP_DBL *fac_data[4]; /* Pointers to unused parts of pSpectralCoefficient */ diff --git a/libAACdec/src/usacdec_fac.cpp b/libAACdec/src/usacdec_fac.cpp index 71ce4a9..6b595d4 100644 --- a/libAACdec/src/usacdec_fac.cpp +++ b/libAACdec/src/usacdec_fac.cpp @@ -142,7 +142,7 @@ FIXP_DBL *CLpd_FAC_GetMemory(CAacDecoderChannelInfo *pAacDecoderChannelInfo, return ptr; } -int CLpd_FAC_Read(HANDLE_FDK_BITSTREAM hBs, FIXP_DBL *pFac, UCHAR *pFacScale, +int CLpd_FAC_Read(HANDLE_FDK_BITSTREAM hBs, FIXP_DBL *pFac, SCHAR *pFacScale, int length, int use_gain, int frame) { FIXP_DBL fac_gain; int fac_gain_e = 0; diff --git a/libAACdec/src/usacdec_fac.h b/libAACdec/src/usacdec_fac.h index bf13552..100a6fa 100644 --- a/libAACdec/src/usacdec_fac.h +++ b/libAACdec/src/usacdec_fac.h @@ -131,7 +131,7 @@ FIXP_DBL *CLpd_FAC_GetMemory(CAacDecoderChannelInfo *pAacDecoderChannelInfo, * Always 0 for FD case. * \return 0 on success, -1 on error. */ -int CLpd_FAC_Read(HANDLE_FDK_BITSTREAM hBs, FIXP_DBL *pFac, UCHAR *pFacScale, +int CLpd_FAC_Read(HANDLE_FDK_BITSTREAM hBs, FIXP_DBL *pFac, SCHAR *pFacScale, int length, int use_gain, int frame); /** diff --git a/libAACdec/src/usacdec_lpd.cpp b/libAACdec/src/usacdec_lpd.cpp index fde34ef..2110172 100644 --- a/libAACdec/src/usacdec_lpd.cpp +++ b/libAACdec/src/usacdec_lpd.cpp @@ -418,6 +418,7 @@ void CLpd_AdaptLowFreqDeemph(FIXP_DBL x[], int lg, FIXP_DBL alfd_gains[], FIXP_DBL tmp_pow2[32]; s = s * 2 + ALFDPOW2_SCALE; + s = fMin(31, s); k = 8; i_max = lg / 4; /* ALFD range = 1600Hz (lg = 6400Hz) */ |