Skip to content
Unverified Commit ca3b7b9d authored by Takashi Iwai's avatar Takashi Iwai Committed by Mark Brown
Browse files

ASoC: Intel: avs: Fix potential buffer overflow by snprintf()



snprintf() returns the would-be-filled size when the string overflows
the given buffer size, hence using this value may result in a buffer
overflow (although it's unrealistic).

This patch replaces it with a safer version, scnprintf() for papering
over such a potential issue.

Fixes: f1b3b320 ("ASoC: Intel: avs: Generic soc component driver")
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
Acked-by: default avatarCezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220801165420.25978-2-tiwai@suse.de


Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent c0fc96fe
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment