[PATCH 2/5] ALSA: snd_usb_caiaq: give better shortname

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Daniel Mack <daniel@xxxxxxxx>
---
 sound/usb/caiaq/device.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/sound/usb/caiaq/device.c b/sound/usb/caiaq/device.c
index 9be0f2e..4756b48 100644
--- a/sound/usb/caiaq/device.c
+++ b/sound/usb/caiaq/device.c
@@ -435,6 +435,11 @@ static int __devinit init_card(struct snd_usb_caiaqdev *dev)
 	strcpy(card->driver, MODNAME);
 	strcpy(card->shortname, dev->product_name);
 
+	/* replace ' ' with '_' in device shortname */
+	for (c = card->shortname; *c; c++)
+		if (*c == ' ')
+			*c = '_';
+
 	len = snprintf(card->longname, sizeof(card->longname),
 		       "%s %s (serial %s, ",
 		       dev->vendor_name, dev->product_name, dev->serial);
-- 
1.6.3.1

_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux