summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/zd1211rw/zd_usb.c
diff options
context:
space:
mode:
authorMaxime Austruy <maxime@tralhalla.org>2007-01-29 00:59:51 +0000
committerJohn W. Linville <linville@tuxdriver.com>2007-02-07 15:23:53 -0500
commit192b775cc811b0e9e0d174ffdd5a814794392482 (patch)
tree2cceaabfda1236abd6a607e33c464f3b4704ba9f /drivers/net/wireless/zd1211rw/zd_usb.c
parent62d0cfcb27cf755cebdc93ca95dabc83608007cd (diff)
[PATCH] zd1211rw: fix potential leak in usb_init
usb_init should call destroy_workqueue when usb_register fails. Signed-off-by: Maxime Austruy <maxime@tralhalla.org> Signed-off-by: Ulrich Kunitz <kune@deine-taler.de> Signed-off-by: Daniel Drake <dsd@gentoo.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/zd1211rw/zd_usb.c')
-rw-r--r--drivers/net/wireless/zd1211rw/zd_usb.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/wireless/zd1211rw/zd_usb.c b/drivers/net/wireless/zd1211rw/zd_usb.c
index 605e96e74057..2468ad662d3d 100644
--- a/drivers/net/wireless/zd1211rw/zd_usb.c
+++ b/drivers/net/wireless/zd1211rw/zd_usb.c
@@ -1128,6 +1128,7 @@ static int __init usb_init(void)
r = usb_register(&driver);
if (r) {
+ destroy_workqueue(zd_workqueue);
printk(KERN_ERR "%s usb_register() failed. Error number %d\n",
driver.name, r);
return r;