Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mtk: fix memory allocation problem #8385

Merged
merged 2 commits into from
Oct 27, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/audio/module_adapter/module_adapter.c
Original file line number Diff line number Diff line change
Expand Up @@ -1450,9 +1450,9 @@ int module_adapter_reset(struct comp_dev *dev)
#endif /* CONFIG_ZEPHYR_DP_SCHEDULER */
if (IS_PROCESSING_MODE_SINK_SOURCE(mod)) {
/* for both LL and DP processing */
for (int i = 0; i < mod->num_of_sources; i++)
for (i = 0; i < mod->num_of_sources; i++)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@singalsu @iuliana-prodan did we not recently change this in another place ? I think the newer xtensa compilers are possibly stricter here and hence we are hitting this now.

mod->sources[i] = NULL;
for (int i = 0; i < mod->num_of_sinks; i++)
for (i = 0; i < mod->num_of_sinks; i++)
mod->sinks[i] = NULL;
mod->num_of_sinks = 0;
mod->num_of_sources = 0;
Expand Down