Commit 5945d98b authored by Daniele Bellucci's avatar Daniele Bellucci Committed by Greg Kroah-Hartman

[PATCH] Another bad audit in drivers/usb/*: usblp

Another better audit:
- If usb_register failes report back its return value
  rather than -1
parent 3b50c0f8
...@@ -1150,10 +1150,13 @@ static struct usb_driver usblp_driver = { ...@@ -1150,10 +1150,13 @@ static struct usb_driver usblp_driver = {
static int __init usblp_init(void) static int __init usblp_init(void)
{ {
if (usb_register(&usblp_driver)) int retval;
return -1; retval = usb_register(&usblp_driver);
if (retval)
goto out;
info(DRIVER_VERSION ": " DRIVER_DESC); info(DRIVER_VERSION ": " DRIVER_DESC);
return 0; out:
return retval;
} }
static void __exit usblp_exit(void) static void __exit usblp_exit(void)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment