summaryrefslogtreecommitdiffstats
path: root/sound/usb
diff options
context:
space:
mode:
authorJesper Juhl <jesper.juhl@gmail.com>2006-03-20 11:27:13 +0100
committerJaroslav Kysela <perex@suse.cz>2006-03-22 10:39:28 +0100
commit878b4789196e3cd470f843854b6b09d963214659 (patch)
tree188c0aa202335575675ca4788c411e07b87c747e /sound/usb
parentd61975fc6b40dadd2cd61fc9535499c7d7b806de (diff)
downloadop-kernel-dev-878b4789196e3cd470f843854b6b09d963214659.zip
op-kernel-dev-878b4789196e3cd470f843854b6b09d963214659.tar.gz
[ALSA] fix resource leak in usbmixer
Modules: USB generic driver We may leak 'namelist' in sound/usb/usbmixer.c::parse_audio_selector_unit() Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/usb')
-rw-r--r--sound/usb/usbmixer.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sound/usb/usbmixer.c b/sound/usb/usbmixer.c
index 0bfea72..8d08b34 100644
--- a/sound/usb/usbmixer.c
+++ b/sound/usb/usbmixer.c
@@ -1468,6 +1468,7 @@ static int parse_audio_selector_unit(struct mixer_build *state, int unitid, unsi
kctl = snd_ctl_new1(&mixer_selectunit_ctl, cval);
if (! kctl) {
snd_printk(KERN_ERR "cannot malloc kcontrol\n");
+ kfree(namelist);
kfree(cval);
return -ENOMEM;
}
OpenPOWER on IntegriCloud