Commit 9741c981 authored by emerit's avatar emerit
Browse files

issue 1070 fixed

parent 2078f2d7
Loading
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -158,6 +158,7 @@

#define FIX_1053_REVERB_RECONFIGURATION                 /* Philips: issue 1053: fix for dynamic switching of acoustic environment */
#define FIX_1060_USAN_ARRAY_BOUNDS                      /* FhG: issue 1060: USAN array-bounds errors */
#define FIX_1070_USAN_SEGFAULT_MC_TO_BIN_BTSW_HEADROT   /* fix 1070 USAN: nullptr-with-offset and Segfaults in 7_1_4 to BINAURAL and BINAURAL_ROOM_REVERB decoding with bitrate switching and head rotation*/ 


/* #################### End BE switches ################################## */
+4 −0
Original line number Diff line number Diff line
@@ -2430,7 +2430,11 @@ ivas_error ivas_jbm_dec_tc_buffer_reconfigure(
    const int16_t n_samples_granularity     /* i  : new granularity of the renderer/buffer  */
)
{
#ifdef FIX_1070_USAN_SEGFAULT_MC_TO_BIN_BTSW_HEADROT
    int32_t nsamp_to_allocate, n_samp_full, n_samp_residual, offset, nchan_residual;
#else
    int16_t nsamp_to_allocate, n_samp_full, n_samp_residual, offset, nchan_residual;
#endif
    int16_t ch_idx;
    DECODER_TC_BUFFER_HANDLE hTcBuffer;

+7 −0
Original line number Diff line number Diff line
@@ -1352,6 +1352,13 @@ static ivas_error ivas_mc_dec_reconfig(
            tc_nchan_full_new = tc_nchan_allocate_new;
        }

#ifdef FIX_1070_USAN_SEGFAULT_MC_TO_BIN_BTSW_HEADROT
        if ( ( st_ivas->renderer_type == RENDERER_BINAURAL_MIXER_CONV || st_ivas->renderer_type == RENDERER_BINAURAL_MIXER_CONV ) && st_ivas->hDecoderConfig->Opt_Headrotation )
        {
            tc_nchan_allocate_new = HOA3_CHANNELS;
            tc_nchan_full_new = tc_nchan_allocate_new;
        }
#endif
        if ( st_ivas->mc_mode == MC_MODE_PARAMMC && st_ivas->hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_MONO && st_ivas->hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_STEREO )
        {
            tc_nchan_full_new = 0;