WSL2-Linux-Kernel/sound/pci/pcxhr
Arnd Bergmann 5051735221 ALSA: pcxhr: fix string overflow warnings
With gcc-7, we get a warning about a possible string overflow:

sound/pci/pcxhr/pcxhr.c: In function 'pcxhr_probe':
sound/pci/pcxhr/pcxhr.c:1647:28: error: ' [PCM #' directive writing 7 bytes into a region of size between 1 and 32 [-Werror=format-overflow=]

The shortname can simply be removed, and the longname can
be changed into a shorter "name" string that is used in three
places. Making it a little shorter (40 bytes) avoids the risk of
overflowing completely, but I also use snprintf() here for
extra clarity.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2017-07-18 17:55:11 +02:00
..
Makefile ALSA: pcxhr - add support for pcxhr stereo sound cards (mixer part) 2008-11-25 12:53:24 +01:00
pcxhr.c ALSA: pcxhr: fix string overflow warnings 2017-07-18 17:55:11 +02:00
pcxhr.h ALSA: pcxhr: fix string overflow warnings 2017-07-18 17:55:11 +02:00
pcxhr_core.c ALSA: pcxhr: Fix missing mutex unlock 2016-04-21 17:37:54 +02:00
pcxhr_core.h ALSA: pcxhr: Use nonatomic PCM ops 2014-09-15 15:52:09 +02:00
pcxhr_hwdep.c lib/vsprintf.c: remove %Z support 2017-02-27 18:43:47 -08:00
pcxhr_hwdep.h [ALSA] Add PCXHR driver 2006-01-03 12:30:26 +01:00
pcxhr_mix22.c ALSA: pci: constify snd_kcontrol_new structures 2017-02-21 22:01:21 +01:00
pcxhr_mix22.h ALSA: pcxhr: Add LTC support 2012-06-20 08:35:37 +02:00
pcxhr_mixer.c ALSA: pci: constify snd_kcontrol_new structures 2017-02-21 22:01:21 +01:00
pcxhr_mixer.h [ALSA] Add PCXHR driver 2006-01-03 12:30:26 +01:00