summaryrefslogtreecommitdiff
path: root/libAACdec
diff options
context:
space:
mode:
authorFraunhofer IIS FDK <audio-fdk@iis.fraunhofer.de>2019-11-13 16:06:56 +0100
committerJean-Michel Trivi <jmtrivi@google.com>2020-01-14 14:53:43 -0800
commit9ab63ce1512780752eb5f54bfd91d132a8611b2a (patch)
tree48281c6c34a51019741cc999e9beac1ebc389a0e /libAACdec
parent3070b0e81bfd3285055bcd4b76a0ca3769bda70b (diff)
downloadaac-9ab63ce1512780752eb5f54bfd91d132a8611b2a.tar.gz
Prevent negation of INT_MIN in CConcealment_ApplyRandomSign().
Bug: 146937601 Test: atest DecoderTestXheAac ; atest DecoderTestAacDrc Change-Id: I9747110eca96b37604df996ef5e86ea58e2d8932
Diffstat (limited to 'libAACdec')
-rw-r--r--libAACdec/src/conceal.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/libAACdec/src/conceal.cpp b/libAACdec/src/conceal.cpp
index 5895cb8..ae98874 100644
--- a/libAACdec/src/conceal.cpp
+++ b/libAACdec/src/conceal.cpp
@@ -1,7 +1,7 @@
/* -----------------------------------------------------------------------------
Software License for The Fraunhofer FDK AAC Codec Library for Android
-© Copyright 1995 - 2018 Fraunhofer-Gesellschaft zur Förderung der angewandten
+© Copyright 1995 - 2019 Fraunhofer-Gesellschaft zur Förderung der angewandten
Forschung e.V. All rights reserved.
1. INTRODUCTION
@@ -1618,7 +1618,7 @@ static void CConcealment_ApplyRandomSign(int randomPhase, FIXP_DBL *spec,
}
if (packedSign & 0x1) {
- spec[i] = -spec[i];
+ spec[i] = -fMax(spec[i], (FIXP_DBL)(MINVAL_DBL + 1));
}
packedSign >>= 1;