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

Skip to content
Commit dfa042fa authored by Eugeniu Rosca's avatar Eugeniu Rosca Committed by Felipe Balbi
Browse files

usb: gadget: u_audio: fix pcm/card naming in g_audio_setup()



Fix below smatch (v0.5.0-4443-g69e9094e11c1) warnings:
drivers/usb/gadget/function/u_audio.c:607 g_audio_setup() warn: strcpy() 'pcm_name' of unknown size might be too large for 'pcm->name'
drivers/usb/gadget/function/u_audio.c:614 g_audio_setup() warn: strcpy() 'card_name' of unknown size might be too large for 'card->driver'
drivers/usb/gadget/function/u_audio.c:615 g_audio_setup() warn: strcpy() 'card_name' of unknown size might be too large for 'card->shortname'

Below commits performed a similar 's/strcpy/strlcpy/' rework:
* v2.6.31 commit 8372d498 ("ALSA: ctxfi - Fix PCM device naming")
* v4.14 commit 003d3e70 ("ALSA: ad1848: fix format string overflow warning")
* v4.14 commit 6d8b04de ("ALSA: cs423x: fix format string overflow warning")

Fixes: eb9fecb9 ("usb: gadget: f_uac2: split out audio core")
Signed-off-by: default avatarEugeniu Rosca <erosca@de.adit-jv.com>
Signed-off-by: default avatarFelipe Balbi <felipe.balbi@linux.intel.com>
parent e87581fe
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