Commit 75256a50 authored by Jan Kiene's avatar Jan Kiene
Browse files

fix usage of uninit value in PLC for SBA with MDCT-ST core

parent b2080fe8
Loading
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -158,6 +158,8 @@

#define ALIGN_SID_SIZE                                  /* Issue 111: make all DTX modes use one SID frame bitrate (5.2 kbps) */

#define FIX_135_MDCT_STEREO_MODE_UNINITIALIZED          /* Issue 135: fix uninitialized value usage in SBA MDCT-Stereo core with PLC */

/* ################## End DEVELOPMENT switches ######################### */
/* clang-format on */
#endif
+4 −0
Original line number Diff line number Diff line
@@ -823,6 +823,10 @@ ivas_error create_cpe_dec(
        set_s( hCPE->hStereoMdct->prev_ms_mask[0], 0, MAX_SFB );
        set_s( hCPE->hStereoMdct->prev_ms_mask[1], 0, MAX_SFB );
        hCPE->hStereoMdct->lastCoh = 1.f;
#ifdef FIX_135_MDCT_STEREO_MODE_UNINITIALIZED
        hCPE->hStereoMdct->mdct_stereo_mode[0] = SMDCT_DUAL_MONO;
        hCPE->hStereoMdct->mdct_stereo_mode[1] = SMDCT_DUAL_MONO;
#endif
    }

    /*-----------------------------------------------------------------*