]> git.baikalelectronics.ru Git - kernel.git/commit
ALSA: sound/usb/format: silence uninitialized variable warnings
authorDan Carpenter <error27@gmail.com>
Sat, 14 Aug 2010 17:29:53 +0000 (19:29 +0200)
committerTakashi Iwai <tiwai@suse.de>
Sun, 15 Aug 2010 12:28:20 +0000 (14:28 +0200)
commit1e16f9fa05057a96b82c218e6aaf213394d70080
tree3c68f297c254caa6d0a0a7634d964df724b6a52a
parent218d3514f88338e30569f1f0ee583a15f3f0e3cc
ALSA: sound/usb/format: silence uninitialized variable warnings

Gcc complains that ret might be used uninitialized:

sound/usb/format.c: In function ‘snd_usb_parse_audio_format’:
sound/usb/format.c:354: warning: ‘ret’ may be used uninitialized in this function
sound/usb/format.c:354: note: ‘ret’ was declared here
sound/usb/format.c:414: warning: ‘ret’ may be used uninitialized in this function
sound/usb/format.c:414: note: ‘ret’ was declared here

I suppose it could be uninitialized if there is ever a UAC_VERSION_3
released. Anyway this patch is worthwhile if only to silence the gcc
warning.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/usb/format.c