summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2025-07-10 12:06:39 +0200
committerTakashi Iwai <tiwai@suse.de>2025-07-11 09:53:19 +0200
commit2d5239eab8ee2d474b5c1a70475f6fe87c74ba57 (patch)
tree1995d320f37d1cee77d039d1408c550f38f1978f
parent0eb71ea6d7f3e64137c19e8d4a3bdcffc57c5b05 (diff)
downloadlinux-2d5239eab8ee2d474b5c1a70475f6fe87c74ba57.tar.gz
linux-2d5239eab8ee2d474b5c1a70475f6fe87c74ba57.zip
ALSA: cs5530: Use safer strscpy() instead of strcpy()
Use a safer function strscpy() instead of strcpy() for copying to arrays. Only idiomatic code replacement, and no functional changes. Signed-off-by: Takashi Iwai <tiwai@suse.de> Link: https://patch.msgid.link/20250710100727.22653-58-tiwai@suse.de
-rw-r--r--sound/pci/cs5530.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/pci/cs5530.c b/sound/pci/cs5530.c
index 532891e67c34..292b65aa758a 100644
--- a/sound/pci/cs5530.c
+++ b/sound/pci/cs5530.c
@@ -207,8 +207,8 @@ static int snd_cs5530_probe(struct pci_dev *pci,
if (err < 0)
return err;
- strcpy(card->driver, "CS5530");
- strcpy(card->shortname, "CS5530 Audio");
+ strscpy(card->driver, "CS5530");
+ strscpy(card->shortname, "CS5530 Audio");
sprintf(card->longname, "%s at 0x%lx", card->shortname, chip->pci_base);
err = snd_card_register(card);