[3.5.y.z,extended,stable] Patch "ALSA: usb/6fire: Fix potential NULL pointer dereference in" has been added to staging queue

Submitted by Luis Henriques on Aug. 13, 2013, 1:59 p.m.


Message ID 1376402386-18527-1-git-send-email-luis.henriques@canonical.com
State New
Headers show

Commit Message

Luis Henriques Aug. 13, 2013, 1:59 p.m.
This is a note to let you know that I have just added a patch titled

    ALSA: usb/6fire: Fix potential NULL pointer dereference in

to the linux-3.5.y-queue branch of the 3.5.y.z extended stable tree 
which can be found at:


If you, or anyone else, feels it should not be added to this tree, please 
reply to this email.

For more information about the 3.5.y.z tree, see



From 40bfb6764d1b132925da0c2ca33791ca0aa590eb Mon Sep 17 00:00:00 2001
From: Sachin Kamat <sachin.kamat@linaro.org>
Date: Wed, 21 Nov 2012 14:36:57 +0530
Subject: [PATCH] ALSA: usb/6fire: Fix potential NULL pointer dereference in

commit 27b2a22c714303d1920e269a8322ff23107694ee upstream.

'rt' was dereferenced before the NULL check.
Moved the code after the check.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Luis Henriques <luis.henriques@canonical.com>
 sound/usb/6fire/comm.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)


Patch hide | download patch | download mbox

diff --git a/sound/usb/6fire/comm.c b/sound/usb/6fire/comm.c
index 6c3d531..1a75c36 100644
--- a/sound/usb/6fire/comm.c
+++ b/sound/usb/6fire/comm.c
@@ -129,12 +129,13 @@  int __devinit usb6fire_comm_init(struct sfire_chip *chip)
 	struct comm_runtime *rt = kzalloc(sizeof(struct comm_runtime),
-	struct urb *urb = &rt->receiver;
+	struct urb *urb;
 	int ret;

 	if (!rt)
 		return -ENOMEM;

+	urb = &rt->receiver;
 	rt->serial = 1;
 	rt->chip = chip;