From 34e8c27c9feea5fe33a722bc90f4c0a9466d6f99 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Mon, 1 Dec 2025 14:29:11 +0100 Subject: [PATCH 01/11] change CI ref --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 81e3d0a3d6..d451624c71 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,7 +1,7 @@ variables: # note: GitLab cannot reference variables defined by users in the include ref:, we need to use a YAML anchor for this # see https://docs.gitlab.com/ci/yaml/includes/#use-variables-with-include for more information - IVAS_CODEC_CI_REF: &IVAS_CODEC_CI_REF main + IVAS_CODEC_CI_REF: &IVAS_CODEC_CI_REF kiene/test-runner-platform-update # If you need to set some config variable only in a local branch, then add an overwrite here # One example is DISABLE_HRTF - this will be set on a branch which is about to be merged and will be removed in a subsequent second MR # this is more easily done directly here in the child repo -- GitLab From 51d3315057bd5a32e1f03d3235f667c3116ad023 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 11 Dec 2025 17:20:17 +0100 Subject: [PATCH 02/11] change log level in ini file --- pytest.ini | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pytest.ini b/pytest.ini index c52e1b7bbd..479461361b 100644 --- a/pytest.ini +++ b/pytest.ini @@ -8,7 +8,8 @@ junit_logging = system-out junit_log_passing_tests = False junit_duration_report = call junit_family = xunit1 -log_file_level = DEBUG +junit_log_passing = true +log_level = INFO log_format = %(asctime)s %(levelname)s %(message)s log_date_format = %Y-%m-%d %H:%M:%S # for pytest-html report: do not log environment variables from the runners -- GitLab From 77c69eebbecf5d37f2f74c02041c13cd5ec996c7 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 11 Dec 2025 18:19:12 +0100 Subject: [PATCH 03/11] try print instead of logging --- tests/renderer/utils.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/tests/renderer/utils.py b/tests/renderer/utils.py index 1aa7370f08..c8fdbccd24 100644 --- a/tests/renderer/utils.py +++ b/tests/renderer/utils.py @@ -67,7 +67,8 @@ from pyaudio3dtools.audiofile import readfile from ..cmp_pcm import cmp_pcm from ..conftest import get_split_idx, parse_properties -def _run_cmd(cmd, test_info=None, env=None ): + +def _run_cmd(cmd, test_info=None, env=None): """ Helper function for running some command. Raises a SystemError if either the return code is non-zero or a USAN printout is detected @@ -103,9 +104,10 @@ def run_isar_ext_rend_cmd(cmd, test_info=None, env=None): def run_ivas_isar_enc_cmd(cmd, test_info=None, env=None): - logging.info(f"\nRunning IVAS ISAR encoder command\n{' '.join(cmd)}\n") + print(f"\nRunning IVAS ISAR encoder command\n{' '.join(cmd)}\n") _run_cmd(cmd, test_info=test_info, env=env) + def run_ivas_isar_dec_cmd(cmd, test_info=None, env=None): if BIN_SUFFIX_MERGETARGET in cmd[0]: logging.info(f"\nREF decoder command:\n\t{' '.join(cmd)}\n") @@ -113,6 +115,7 @@ def run_ivas_isar_dec_cmd(cmd, test_info=None, env=None): logging.info(f"\nDUT decoder command:\n\t{' '.join(cmd)}\n") _run_cmd(cmd, test_info=test_info, env=env) + def run_isar_post_rend_cmd(cmd, test_info=None, env=None): logging.info(f"\nRunning ISAR post renderer command\n{' '.join(cmd)}\n") _run_cmd(cmd, test_info=test_info, env=env) @@ -771,19 +774,19 @@ def scene_description_file(in_fmt, metadata_tmp, n_obj, input_file, in_meta_file metadata_tmp ).parent # File names must be relative to config file location fp_meta.write(f"{os.path.relpath(input_file, currdir)}\n") # Input file - fp_meta.write(f"{n_obj+1}\n") # Number of sources + fp_meta.write(f"{n_obj + 1}\n") # Number of sources for n in range(0, n_obj): if in_meta_files[n] == "NULL": md_file = "1\n1,0,0" # NULL metadata position: azim=0,elev=0 for 1 frame, looped throughout all frames. else: md_file = os.path.relpath(in_meta_files[n], currdir) - fp_meta.write(f"ISM\n{n+1}\n{md_file}\n") # ISM metadata + fp_meta.write(f"ISM\n{n + 1}\n{md_file}\n") # ISM metadata if "OSBA" in in_fmt: fp_meta.write( "gain_dB:-6\n" ) # Set -6 dB on all components for OSBA to match IVAS_dec fp_meta.write(f"{in_fmt.split('_')[0][1:]}\n") # SBA or MASA - fp_meta.write(f"{n_obj+1}\n") + fp_meta.write(f"{n_obj + 1}\n") fp_meta.write(f"{in_fmt.split('_')[-1]}\n") # SBA or MASA parameter if "OMASA" in in_fmt: fp_meta.write( -- GitLab From 3ee6fa3fbaed6888987d8dcf5ad05c9acc64d34e Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 11 Dec 2025 18:34:46 +0100 Subject: [PATCH 04/11] Revert "try print instead of logging" This reverts commit 77c69eebbecf5d37f2f74c02041c13cd5ec996c7. --- tests/renderer/utils.py | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/tests/renderer/utils.py b/tests/renderer/utils.py index c8fdbccd24..1aa7370f08 100644 --- a/tests/renderer/utils.py +++ b/tests/renderer/utils.py @@ -67,8 +67,7 @@ from pyaudio3dtools.audiofile import readfile from ..cmp_pcm import cmp_pcm from ..conftest import get_split_idx, parse_properties - -def _run_cmd(cmd, test_info=None, env=None): +def _run_cmd(cmd, test_info=None, env=None ): """ Helper function for running some command. Raises a SystemError if either the return code is non-zero or a USAN printout is detected @@ -104,10 +103,9 @@ def run_isar_ext_rend_cmd(cmd, test_info=None, env=None): def run_ivas_isar_enc_cmd(cmd, test_info=None, env=None): - print(f"\nRunning IVAS ISAR encoder command\n{' '.join(cmd)}\n") + logging.info(f"\nRunning IVAS ISAR encoder command\n{' '.join(cmd)}\n") _run_cmd(cmd, test_info=test_info, env=env) - def run_ivas_isar_dec_cmd(cmd, test_info=None, env=None): if BIN_SUFFIX_MERGETARGET in cmd[0]: logging.info(f"\nREF decoder command:\n\t{' '.join(cmd)}\n") @@ -115,7 +113,6 @@ def run_ivas_isar_dec_cmd(cmd, test_info=None, env=None): logging.info(f"\nDUT decoder command:\n\t{' '.join(cmd)}\n") _run_cmd(cmd, test_info=test_info, env=env) - def run_isar_post_rend_cmd(cmd, test_info=None, env=None): logging.info(f"\nRunning ISAR post renderer command\n{' '.join(cmd)}\n") _run_cmd(cmd, test_info=test_info, env=env) @@ -774,19 +771,19 @@ def scene_description_file(in_fmt, metadata_tmp, n_obj, input_file, in_meta_file metadata_tmp ).parent # File names must be relative to config file location fp_meta.write(f"{os.path.relpath(input_file, currdir)}\n") # Input file - fp_meta.write(f"{n_obj + 1}\n") # Number of sources + fp_meta.write(f"{n_obj+1}\n") # Number of sources for n in range(0, n_obj): if in_meta_files[n] == "NULL": md_file = "1\n1,0,0" # NULL metadata position: azim=0,elev=0 for 1 frame, looped throughout all frames. else: md_file = os.path.relpath(in_meta_files[n], currdir) - fp_meta.write(f"ISM\n{n + 1}\n{md_file}\n") # ISM metadata + fp_meta.write(f"ISM\n{n+1}\n{md_file}\n") # ISM metadata if "OSBA" in in_fmt: fp_meta.write( "gain_dB:-6\n" ) # Set -6 dB on all components for OSBA to match IVAS_dec fp_meta.write(f"{in_fmt.split('_')[0][1:]}\n") # SBA or MASA - fp_meta.write(f"{n_obj + 1}\n") + fp_meta.write(f"{n_obj+1}\n") fp_meta.write(f"{in_fmt.split('_')[-1]}\n") # SBA or MASA parameter if "OMASA" in in_fmt: fp_meta.write( -- GitLab From 6ee74fc2ea7aba3ea63f005cc0a5a525d20fa4e3 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 11 Dec 2025 18:34:56 +0100 Subject: [PATCH 05/11] Revert "change log level in ini file" This reverts commit 51d3315057bd5a32e1f03d3235f667c3116ad023. --- pytest.ini | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pytest.ini b/pytest.ini index 479461361b..c52e1b7bbd 100644 --- a/pytest.ini +++ b/pytest.ini @@ -8,8 +8,7 @@ junit_logging = system-out junit_log_passing_tests = False junit_duration_report = call junit_family = xunit1 -junit_log_passing = true -log_level = INFO +log_file_level = DEBUG log_format = %(asctime)s %(levelname)s %(message)s log_date_format = %Y-%m-%d %H:%M:%S # for pytest-html report: do not log environment variables from the runners -- GitLab From 2b2b81257030c48380e8a38943f49dc09db855e0 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 11 Dec 2025 18:35:10 +0100 Subject: [PATCH 06/11] log all output in junit xml reports --- pytest.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pytest.ini b/pytest.ini index c52e1b7bbd..4d5e739363 100644 --- a/pytest.ini +++ b/pytest.ini @@ -3,7 +3,7 @@ [pytest] addopts = --tb=short -n auto -v # Write captured system-out log messages to JUnit report. -junit_logging = system-out +junit_logging = all # Do not capture log information for passing tests to JUnit report. junit_log_passing_tests = False junit_duration_report = call -- GitLab From dcfd0eff3c15545e10f6027cde75729a6c14be9d Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Fri, 12 Dec 2025 09:44:22 +0100 Subject: [PATCH 07/11] print errors in failing renderer calls to add to system-out --- tests/renderer/utils.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/tests/renderer/utils.py b/tests/renderer/utils.py index 1aa7370f08..f7c1b38462 100644 --- a/tests/renderer/utils.py +++ b/tests/renderer/utils.py @@ -67,7 +67,8 @@ from pyaudio3dtools.audiofile import readfile from ..cmp_pcm import cmp_pcm from ..conftest import get_split_idx, parse_properties -def _run_cmd(cmd, test_info=None, env=None ): + +def _run_cmd(cmd, test_info=None, env=None): """ Helper function for running some command. Raises a SystemError if either the return code is non-zero or a USAN printout is detected @@ -78,6 +79,7 @@ def _run_cmd(cmd, test_info=None, env=None ): # check for USAN error first if "UndefinedBehaviorSanitizer" in stdout: error = f"USAN error detected in stdout of command: {' '.join(cmd)}\n{stdout}" + print(error) if test_info is not None: test_info.error = error raise SystemError(error) @@ -87,6 +89,7 @@ def _run_cmd(cmd, test_info=None, env=None ): proc.check_returncode() except sp.CalledProcessError as e: error = f"Command returned non-zero exit status ({e.returncode}): {' '.join(e.cmd)}\n{e.stderr}\n{e.stdout}" + print(error) if test_info is not None: test_info.error = error raise SystemError(error) @@ -106,6 +109,7 @@ def run_ivas_isar_enc_cmd(cmd, test_info=None, env=None): logging.info(f"\nRunning IVAS ISAR encoder command\n{' '.join(cmd)}\n") _run_cmd(cmd, test_info=test_info, env=env) + def run_ivas_isar_dec_cmd(cmd, test_info=None, env=None): if BIN_SUFFIX_MERGETARGET in cmd[0]: logging.info(f"\nREF decoder command:\n\t{' '.join(cmd)}\n") @@ -113,6 +117,7 @@ def run_ivas_isar_dec_cmd(cmd, test_info=None, env=None): logging.info(f"\nDUT decoder command:\n\t{' '.join(cmd)}\n") _run_cmd(cmd, test_info=test_info, env=env) + def run_isar_post_rend_cmd(cmd, test_info=None, env=None): logging.info(f"\nRunning ISAR post renderer command\n{' '.join(cmd)}\n") _run_cmd(cmd, test_info=test_info, env=env) @@ -771,19 +776,19 @@ def scene_description_file(in_fmt, metadata_tmp, n_obj, input_file, in_meta_file metadata_tmp ).parent # File names must be relative to config file location fp_meta.write(f"{os.path.relpath(input_file, currdir)}\n") # Input file - fp_meta.write(f"{n_obj+1}\n") # Number of sources + fp_meta.write(f"{n_obj + 1}\n") # Number of sources for n in range(0, n_obj): if in_meta_files[n] == "NULL": md_file = "1\n1,0,0" # NULL metadata position: azim=0,elev=0 for 1 frame, looped throughout all frames. else: md_file = os.path.relpath(in_meta_files[n], currdir) - fp_meta.write(f"ISM\n{n+1}\n{md_file}\n") # ISM metadata + fp_meta.write(f"ISM\n{n + 1}\n{md_file}\n") # ISM metadata if "OSBA" in in_fmt: fp_meta.write( "gain_dB:-6\n" ) # Set -6 dB on all components for OSBA to match IVAS_dec fp_meta.write(f"{in_fmt.split('_')[0][1:]}\n") # SBA or MASA - fp_meta.write(f"{n_obj+1}\n") + fp_meta.write(f"{n_obj + 1}\n") fp_meta.write(f"{in_fmt.split('_')[-1]}\n") # SBA or MASA parameter if "OMASA" in in_fmt: fp_meta.write( -- GitLab From 7d9ac373bff7cd88c2d69a8fe7a2240746650aa1 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Tue, 16 Dec 2025 17:09:45 +0100 Subject: [PATCH 08/11] initialize nb_bits_metadata to zero --- lib_com/options.h | 1 + lib_dec/ivas_jbm_dec.c | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/lib_com/options.h b/lib_com/options.h index fb505d58f4..24531cc271 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -170,6 +170,7 @@ #define FIX_2274_OOB_INDEXING_IN_CORRMATRIX /* FhG: fix OOB indexing complaint */ #define FIX_2278_OOB_INDEXING_IN_CLOSED_LOOP_PIT_SEARCH /* FhG: fix oob indexing USAN complaint */ #define FIX_2287_MCT_MDCT_STEREO_DATA_MALLOC_SIZE /* FhG: correct allocation size for STEREO_MDCT_DEC_DATA struct */ +#define FIX_1487_ACCESS_OF_UNINIT_VAL_FROM_ARR_ISM_DTX /* FhG: init nb_bits_metadata to zero */ /* #################### End BE switches ################################## */ diff --git a/lib_dec/ivas_jbm_dec.c b/lib_dec/ivas_jbm_dec.c index 4f0acd6364..c7b3cf90a6 100644 --- a/lib_dec/ivas_jbm_dec.c +++ b/lib_dec/ivas_jbm_dec.c @@ -101,6 +101,10 @@ ivas_error ivas_jbm_dec_tc( } } +#ifdef FIX_1487_ACCESS_OF_UNINIT_VAL_FROM_ARR_ISM_DTX + set_s( nb_bits_metadata, 0, MAX_SCE + 1 ); +#endif + /*----------------------------------------------------------------* * Decoding + pre-rendering *----------------------------------------------------------------*/ -- GitLab From 6ba4e463107ec5f0c1dfb479187df266cbdc58e3 Mon Sep 17 00:00:00 2001 From: Erik Norvell Date: Tue, 16 Dec 2025 17:39:06 +0100 Subject: [PATCH 09/11] Add USAN fix under FIX_1474_USAN_TRANS_INV --- lib_com/options.h | 1 + lib_com/trans_direct.c | 16 ++++++++++++++++ lib_com/trans_inv.c | 16 ++++++++++++++++ 3 files changed, 33 insertions(+) diff --git a/lib_com/options.h b/lib_com/options.h index fb505d58f4..9af4c680b2 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -170,6 +170,7 @@ #define FIX_2274_OOB_INDEXING_IN_CORRMATRIX /* FhG: fix OOB indexing complaint */ #define FIX_2278_OOB_INDEXING_IN_CLOSED_LOOP_PIT_SEARCH /* FhG: fix oob indexing USAN complaint */ #define FIX_2287_MCT_MDCT_STEREO_DATA_MALLOC_SIZE /* FhG: correct allocation size for STEREO_MDCT_DEC_DATA struct */ +#define FIX_1474_USAN_TRANS_INV /* Eri: Fix USAN out-of-bounds warning. No OOB occurs, but the pointer is set to point to uninitialized memory. */ /* #################### End BE switches ################################## */ diff --git a/lib_com/trans_direct.c b/lib_com/trans_direct.c index ece6934929..540d6ec751 100644 --- a/lib_com/trans_direct.c +++ b/lib_com/trans_direct.c @@ -100,19 +100,31 @@ void direct_transform( in32_r16[i] = in32[L - 1 - i]; in32_r16[L - 1 - i] = in32[i]; } + +#ifndef FIX_1474_USAN_TRANS_INV iseg = in32_r16 - segment_length / 4; +#endif oseg = out32; wh = win + segment_length / 4; wl = win + segment_length / 4 - 1; +#ifdef FIX_1474_USAN_TRANS_INV + sh = in32_r16 + 2 * segment_length / 4; + sl = in32_r16 + 2 * segment_length / 4 - 1; +#else sh = iseg + 3 * segment_length / 4; sl = iseg + 3 * segment_length / 4 - 1; +#endif for ( i = 0; i < segment_length / 4; i++ ) { dctin32[i] = ( ( *wl-- * *sl-- ) - ( *wh++ * *sh++ ) ); } +#ifdef FIX_1474_USAN_TRANS_INV + sl = in32_r16 + segment_length / 4 - 1; +#else sl = iseg + segment_length / 2 - 1; +#endif for ( i = 0; i < segment_length / 4; i++ ) { @@ -121,7 +133,11 @@ void direct_transform( edct( dctin32, oseg, segment_length / 2, element_mode ); +#ifdef FIX_1474_USAN_TRANS_INV + iseg = in32_r16 + segment_length / 4; +#else iseg = iseg + segment_length / 2; +#endif oseg = oseg + segment_length / 2; for ( seg = 1; seg < NUM_TIME_SWITCHING_BLOCKS - 1; seg++ ) diff --git a/lib_com/trans_inv.c b/lib_com/trans_inv.c index 620be7a178..183595767c 100644 --- a/lib_com/trans_inv.c +++ b/lib_com/trans_inv.c @@ -838,22 +838,38 @@ void inverse_transform( } } +#ifdef FIX_1474_USAN_TRANS_INV + out_segment = out_alias; +#else out_segment = out_alias - segment_length / 4; +#endif in_segment = in_mdct_modif; iedct_short( in_segment, alias, segment_length, element_mode ); for ( ta = segment_length / 4; ta < segment_length / 2; ta++ ) { +#ifdef FIX_1474_USAN_TRANS_INV + *out_segment++ = alias[ta]; +#else out_segment[ta] = alias[ta]; +#endif } for ( ta = segment_length / 2; ta < segment_length; ta++ ) { +#ifdef FIX_1474_USAN_TRANS_INV + *out_segment++ = alias[ta] * win[ta]; +#else out_segment[ta] = alias[ta] * win[ta]; +#endif } +#ifdef FIX_1474_USAN_TRANS_INV + out_segment = out_alias + segment_length / 4; +#else out_segment = out_segment + segment_length / 2; +#endif in_segment = in_segment + segment_length / 2; for ( seg = 1; seg < NUM_TIME_SWITCHING_BLOCKS - 1; seg++ ) -- GitLab From f6f9293cf3da50912e23a4eb3d35941e01507d15 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 17 Dec 2025 10:24:43 +0100 Subject: [PATCH 10/11] init pointer array regardless of having samples to flush or not --- lib_com/options.h | 1 + lib_dec/ivas_jbm_dec.c | 14 ++++++++++++++ 2 files changed, 15 insertions(+) diff --git a/lib_com/options.h b/lib_com/options.h index 57c086afb3..7b40ab0442 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -170,6 +170,7 @@ #define FIX_2274_OOB_INDEXING_IN_CORRMATRIX /* FhG: fix OOB indexing complaint */ #define FIX_2278_OOB_INDEXING_IN_CLOSED_LOOP_PIT_SEARCH /* FhG: fix oob indexing USAN complaint */ #define FIX_2287_MCT_MDCT_STEREO_DATA_MALLOC_SIZE /* FhG: correct allocation size for STEREO_MDCT_DEC_DATA struct */ +#define FIX_1486_INIT_OUTPUT_POINTERS /* FhG: always initialize pointers in renderer flush */ /* #################### End BE switches ################################## */ diff --git a/lib_dec/ivas_jbm_dec.c b/lib_dec/ivas_jbm_dec.c index 4f0acd6364..736d0cbd38 100644 --- a/lib_dec/ivas_jbm_dec.c +++ b/lib_dec/ivas_jbm_dec.c @@ -1408,6 +1408,9 @@ ivas_error ivas_jbm_dec_flush_renderer( int16_t n_samples_still_available; int16_t n_slots_still_available; int16_t n_samples_to_render; +#ifdef FIX_1486_INIT_OUTPUT_POINTERS + int16_t ch_idx; +#endif DECODER_TC_BUFFER_HANDLE hTcBuffer; float *p_output[MAX_LS_CHANNELS + MAX_NUM_OBJECTS]; @@ -1416,6 +1419,13 @@ ivas_error ivas_jbm_dec_flush_renderer( return IVAS_ERR_OK; } +#ifdef FIX_1486_INIT_OUTPUT_POINTERS + for ( ch_idx = 0; ch_idx < MAX_OUTPUT_CHANNELS + MAX_NUM_OBJECTS; ch_idx++ ) + { + p_output[ch_idx] = st_ivas->p_output_f[ch_idx]; + } +#endif + *nSamplesRendered = 0; hTcBuffer = st_ivas->hTcBuffer; @@ -1432,8 +1442,10 @@ ivas_error ivas_jbm_dec_flush_renderer( if ( n_slots_still_available ) { +#ifndef FIX_1486_INIT_OUTPUT_POINTERS int16_t ch_idx; +#endif /* render available full slots (with new lower granularity) */ for ( ch_idx = 0; ch_idx < max( hTcBuffer->nchan_transport_jbm, hTcBuffer->nchan_buffer_full ); ch_idx++ ) { @@ -1453,10 +1465,12 @@ ivas_error ivas_jbm_dec_flush_renderer( hTcBuffer->n_samples_flushed = n_samples_to_render; hTcBuffer->n_samples_rendered = 0; +#ifndef FIX_1486_INIT_OUTPUT_POINTERS for ( ch_idx = 0; ch_idx < MAX_OUTPUT_CHANNELS + MAX_NUM_OBJECTS; ch_idx++ ) { p_output[ch_idx] = st_ivas->p_output_f[ch_idx]; } +#endif if ( st_ivas->ivas_format == ISM_FORMAT ) { -- GitLab From 4fe177b0a45d4c9c15c3ce643a7e6b929a1eb8b1 Mon Sep 17 00:00:00 2001 From: vaclav Date: Wed, 17 Dec 2025 11:07:28 +0100 Subject: [PATCH 11/11] zero out the buffer at place where it is handled --- lib_com/options.h | 2 +- lib_dec/ivas_ism_dtx_dec.c | 6 ++++++ lib_dec/ivas_jbm_dec.c | 4 ---- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/lib_com/options.h b/lib_com/options.h index 24531cc271..728cd426cb 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -170,7 +170,7 @@ #define FIX_2274_OOB_INDEXING_IN_CORRMATRIX /* FhG: fix OOB indexing complaint */ #define FIX_2278_OOB_INDEXING_IN_CLOSED_LOOP_PIT_SEARCH /* FhG: fix oob indexing USAN complaint */ #define FIX_2287_MCT_MDCT_STEREO_DATA_MALLOC_SIZE /* FhG: correct allocation size for STEREO_MDCT_DEC_DATA struct */ -#define FIX_1487_ACCESS_OF_UNINIT_VAL_FROM_ARR_ISM_DTX /* FhG: init nb_bits_metadata to zero */ +#define FIX_1487_ACCESS_OF_UNINIT_VAL_FROM_ARR_ISM_DTX /* FhG/VA: init nb_bits_metadata to zero */ /* #################### End BE switches ################################## */ diff --git a/lib_dec/ivas_ism_dtx_dec.c b/lib_dec/ivas_ism_dtx_dec.c index 3164218b41..dc0b27813b 100644 --- a/lib_dec/ivas_ism_dtx_dec.c +++ b/lib_dec/ivas_ism_dtx_dec.c @@ -120,6 +120,12 @@ void ivas_ism_dtx_dec( nb_bits_metadata[ch] = nb_bits_metadata[sce_id_dtx]; } } +#ifdef FIX_1487_ACCESS_OF_UNINIT_VAL_FROM_ARR_ISM_DTX + else + { + set_s( nb_bits_metadata, 0, st_ivas->nchan_transport ); + } +#endif if ( !st_ivas->bfi ) { diff --git a/lib_dec/ivas_jbm_dec.c b/lib_dec/ivas_jbm_dec.c index c7b3cf90a6..4f0acd6364 100644 --- a/lib_dec/ivas_jbm_dec.c +++ b/lib_dec/ivas_jbm_dec.c @@ -101,10 +101,6 @@ ivas_error ivas_jbm_dec_tc( } } -#ifdef FIX_1487_ACCESS_OF_UNINIT_VAL_FROM_ARR_ISM_DTX - set_s( nb_bits_metadata, 0, MAX_SCE + 1 ); -#endif - /*----------------------------------------------------------------* * Decoding + pre-rendering *----------------------------------------------------------------*/ -- GitLab