aboutsummaryrefslogtreecommitdiff
path: root/silk/fixed/schur64_FIX.c
diff options
context:
space:
mode:
authorFelicia Lim <flim@google.com>2017-07-05 17:36:56 -0700
committerFelicia Lim <flim@google.com>2017-07-07 09:42:55 -0700
commit0c2090c324e4f2ba2a8621c8b083559bab74c7c5 (patch)
treefea1ab0038bc4102569d1ab4ee57a0f973895570 /silk/fixed/schur64_FIX.c
parenta7703b70699299f078a189e19b6915120cded732 (diff)
downloadlibopus-0c2090c324e4f2ba2a8621c8b083559bab74c7c5.tar.gz
Change-Id: I551f1de5c5e121ac1275334e67c7e0f96ab18114 Test: - verified builds for arm*/mips*/x86* - checked functionality using an emulator and stagefright
Diffstat (limited to 'silk/fixed/schur64_FIX.c')
-rw-r--r--silk/fixed/schur64_FIX.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/silk/fixed/schur64_FIX.c b/silk/fixed/schur64_FIX.c
index 764a10ef..b2cb12d9 100644
--- a/silk/fixed/schur64_FIX.c
+++ b/silk/fixed/schur64_FIX.c
@@ -43,7 +43,7 @@ opus_int32 silk_schur64( /* O returns residual ene
opus_int32 C[ SILK_MAX_ORDER_LPC + 1 ][ 2 ];
opus_int32 Ctmp1_Q30, Ctmp2_Q30, rc_tmp_Q31;
- silk_assert( order==6||order==8||order==10||order==12||order==14||order==16 );
+ silk_assert( order >= 0 && order <= SILK_MAX_ORDER_LPC );
/* Check for invalid input */
if( c[ 0 ] <= 0 ) {
@@ -51,9 +51,10 @@ opus_int32 silk_schur64( /* O returns residual ene
return 0;
}
- for( k = 0; k < order + 1; k++ ) {
+ k = 0;
+ do {
C[ k ][ 0 ] = C[ k ][ 1 ] = c[ k ];
- }
+ } while( ++k <= order );
for( k = 0; k < order; k++ ) {
/* Check that we won't be getting an unstable rc, otherwise stop here. */