Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.xiph.org/xiph/opus.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelicia Lim <flim@google.com>2016-03-30 16:11:06 +0300
committerJean-Marc Valin <jmvalin@jmvalin.ca>2016-03-30 19:25:27 +0300
commite40df01625fe4a8807526ab76ec44d85ef6d055f (patch)
treed86704c13e04142d69376ce926d19afdb81447b1
parentbe9e747bcc542c277d30f6c78a57b0940e0c5b5e (diff)
Fix valgrind unaddressable mem read error
Signed-off-by: Jean-Marc Valin <jmvalin@jmvalin.ca>
-rw-r--r--silk/NLSF_encode.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/silk/NLSF_encode.c b/silk/NLSF_encode.c
index 03a036fd..f03c3f1c 100644
--- a/silk/NLSF_encode.c
+++ b/silk/NLSF_encode.c
@@ -46,7 +46,7 @@ opus_int32 silk_NLSF_encode( /* O Returns
)
{
opus_int i, s, ind1, bestIndex, prob_Q8, bits_q7;
- opus_int32 W_tmp_Q9;
+ opus_int32 W_tmp_Q9, ret;
VARDECL( opus_int32, err_Q26 );
VARDECL( opus_int32, RD_Q25 );
VARDECL( opus_int, tempIndices1 );
@@ -131,6 +131,7 @@ opus_int32 silk_NLSF_encode( /* O Returns
/* Decode */
silk_NLSF_decode( pNLSF_Q15, NLSFIndices, psNLSF_CB );
+ ret = RD_Q25[ 0 ];
RESTORE_STACK;
- return RD_Q25[ 0 ];
+ return ret;
}