projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e0d32e3
)
ALSA: usb-audio: Check for possible chip NULL pointer before clearing probing flag
author
Thomas Pfaff
<
[email protected]
>
Mon, 26 Sep 2011 13:43:59 +0000
(15:43 +0200)
committer
Takashi Iwai
<
[email protected]
>
Mon, 26 Sep 2011 13:48:47 +0000
(15:48 +0200)
Before clearing the probing flag in the error exit path, check that the
chip pointer is not NULL.
Signed-off-by: Thomas Pfaff <
[email protected]
>
Cc: <
[email protected]
> [2.6.39+]
Signed-off-by: Takashi Iwai <
[email protected]
>
sound/usb/card.c
patch
|
blob
|
history
diff --git
a/sound/usb/card.c
b/sound/usb/card.c
index ed120ca2353dd67f4d71efea6f330dda3354131f..d8f2bf4014589bec80c95af42a8c55bd08a87865 100644
(file)
--- a/
sound/usb/card.c
+++ b/
sound/usb/card.c
@@
-530,9
+530,11
@@
snd_usb_audio_probe(struct usb_device *dev,
return chip;
__error:
- if (chip && !chip->num_interfaces)
- snd_card_free(chip->card);
- chip->probing = 0;
+ if (chip) {
+ if (!chip->num_interfaces)
+ snd_card_free(chip->card);
+ chip->probing = 0;
+ }
mutex_unlock(®ister_mutex);
__err_val:
return NULL;