From 360a5812b9237a1dcc8da259e6e570a4b45379bd Mon Sep 17 00:00:00 2001 From: Pierre-Louis Bossart Date: Thu, 12 Aug 2021 17:59:03 -0500 Subject: ALSA: core: control_led: use strscpy instead of strlcpy strlcpy is deprecated, use its safe replacement Signed-off-by: Pierre-Louis Bossart Reviewed-by: Ranjani Sridharan Reviewed-by: Bard Liao Reviewed-by: Paul Olaru Reviewed-by: Kai Vehmanen Link: https://lore.kernel.org/r/20210812225904.171529-2-pierre-louis.bossart@linux.intel.com Signed-off-by: Takashi Iwai --- sound/core/control_led.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sound/core') diff --git a/sound/core/control_led.c b/sound/core/control_led.c index 764058cc345d..a95332b2b90b 100644 --- a/sound/core/control_led.c +++ b/sound/core/control_led.c @@ -564,7 +564,7 @@ static ssize_t set_led_id(struct snd_ctl_led_card *led_card, const char *buf, si else { for (; *s >= ' '; s++); *s = '\0'; - strlcpy(id.name, buf2, sizeof(id.name)); + strscpy(id.name, buf2, sizeof(id.name)); } break; } -- cgit