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:
f941f69
)
drivers/usb/misc/usbtest.c: add kfrees
author
Julia Lawall
<Julia.Lawall@lip6.fr>
Sun, 25 Mar 2012 19:08:32 +0000
(21:08 +0200)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Wed, 18 Apr 2012 21:13:52 +0000
(14:13 -0700)
Free the two previously allocated buffers before exiting the function in an
error case.
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/misc/usbtest.c
patch
|
blob
|
history
diff --git
a/drivers/usb/misc/usbtest.c
b/drivers/usb/misc/usbtest.c
index cac67dea2bac32018c48dcd84adfa9dbcdda0494..9dcb68f04f03025265f3747e6f7bf072ab1b8958 100644
(file)
--- a/
drivers/usb/misc/usbtest.c
+++ b/
drivers/usb/misc/usbtest.c
@@
-2277,6
+2277,8
@@
usbtest_probe(struct usb_interface *intf, const struct usb_device_id *id)
if (status < 0) {
WARNING(dev, "couldn't get endpoints, %d\n",
status);
+ kfree(dev->buf);
+ kfree(dev);
return status;
}
/* may find bulk or ISO pipes */