Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d9ed13a3 authored by Karthikeyan Mani's avatar Karthikeyan Mani Committed by Gerrit - the friendly Code Review server
Browse files

asoc: msm-audio-effects: initialize struct before use



Memset the param header struct to null values before
using or passing it to other functions.

Change-Id: I09ae686e62c8812ea267d4f809529b324fb7106d
Signed-off-by: default avatarKarthikeyan Mani <kmani@codeaurora.org>
parent e4c2393a
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -141,6 +141,7 @@ int msm_audio_effects_virtualizer_handler(struct audio_client *ac,
	pr_debug("%s: device: %d\n", __func__, devices);
	updt_params = (u8 *) params;
	/* Set MID and IID once at top and only update param specific fields*/
	memset(&param_hdr, 0, sizeof(param_hdr));
	param_hdr.module_id = AUDPROC_MODULE_ID_VIRTUALIZER;
	param_hdr.instance_id = INSTANCE_ID_0;
	for (i = 0; i < num_commands; i++) {