Commit a427ea8b authored by sagnowski's avatar sagnowski
Browse files

Merge branch '1349-crash-possible-in-encoding-of-tns-data-for-mdct-stereo-core' into 'main'

Resolve "Crash possible in Encoding of TNS Data for MDCT-Stereo core"

See merge request !2275
parents 3089a7e5 d46964a3
Loading
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -173,6 +173,7 @@
#define FIX_1383_HEAD_TRACK_SANITIZER                   /* Nok: issue 1383: Fix head tracking struc values reading in renderer */
#define FIX_1385_INIT_IGF_STOP_FREQ                     /* FhG: Initialize infoIGFStopFreq in init_igf_dec() */
#define FIX_1387_INIT_PRM_SQQ                           /* FhG: initialize pointer prm_sqQ, which might be uninitialized in case of bfi == 1 */
#define FIX_1349_TNS_CRASH                              /* FhG: Fix crash in TNS entropy coding, in case order of joint TNS coding is reduced to 0 */


/* #################### End BE switches ################################## */
+9 −0
Original line number Diff line number Diff line
@@ -332,6 +332,15 @@ void TNSAnalysisStereo(

                                        pFilter[0]->order = pFilter[1]->order = maxOrder;
                                    }
#ifdef FIX_1349_TNS_CRASH
                                    else
                                    {
                                        pFilter[0]->filterType = TNS_FILTER_OFF;
                                        pFilter[1]->filterType = TNS_FILTER_OFF;
                                        sts[0]->hTcxEnc->tnsData[k].nFilters = 0;
                                        sts[1]->hTcxEnc->tnsData[k].nFilters = 0;
                                    }
#endif
                                }
                            }
                        }