diff --git a/lib_com/options.h b/lib_com/options.h index fb7a4bebace6c1a878be6d1fe68dbff124e843b5..5cfb7d35c9e92d020798021cdc1b99c05c63e2c9 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -168,6 +168,7 @@ /* any switch which is non-be wrt selection floating point code */ /* all switches in this category should start with "NONBE_" */ +#define NON_BE_FIX_EVS_USAN_ERR_IN_WAVEADJUST /* FhG: address issue 1037 */ #define NON_BE_1055_RESET_LP_MEMORIES /* VA: issue 1055: Correctly reset LP filter MA and AR memories in bitrate switching */ #define NONBE_FIX_1058_DECODER_ERROR_WITH_REVERB_ROOM /* FhG: issue 1058: do not initialize EFAP when IntSetup is HOA3 */ #define NONBE_FIX_1056_ISM_RATE_SWITCH /* FhG: Fix #1056: fix TC buffer udpate on a ISM rate switch */ @@ -175,7 +176,6 @@ #define NONBE_FIX_1054_NEGATIVE_LVQ_INDEX /* Nokia: issue 1054: Input to decode_comb in deindex_lvq_SHB should be positive */ #define NONBE_FIX_1063_DIV_BY_ZERO_SUMNRG /* VoiceAge: issue 1063: division by zero for angle_rot feature in the UNCLR classifier */ - /* ##################### End NON-BE switches ########################### */ /* ################## End DEVELOPMENT switches ######################### */ diff --git a/lib_dec/waveadjust_fec_dec.c b/lib_dec/waveadjust_fec_dec.c index cc5223cfbc3abf2fb8674f47aed9eeb5a16f9dcc..d5cf31cef8dfe1b28cb94a906563293d668c7df3 100644 --- a/lib_dec/waveadjust_fec_dec.c +++ b/lib_dec/waveadjust_fec_dec.c @@ -742,7 +742,13 @@ void concealment_decode( /* sign randomization */ for ( i = 0; i < hPlcInfo->L_frameTCX; i++ ) { +#ifdef NON_BE_FIX_EVS_USAN_ERR_IN_WAVEADJUST + int16_t rnd; + rnd = own_random( seed ); + sign = ( rnd >= 0 ) - ( rnd < 0 ); +#else sign = ( ( own_random( seed ) >> 15 ) << 1 ) + 1; +#endif invkoef[i] *= sign; } }