mirror of
https://github.com/torvalds/linux.git
synced 2026-06-10 07:32:29 +02:00
USB: whiteheat: fix memory leak in error path
commit c129197c99 upstream.
Make sure command buffer is deallocated in case of errors during attach.
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Cc: <support@connecttech.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
974ee86a47
commit
a48db008e3
|
|
@ -576,6 +576,7 @@ static int whiteheat_attach(struct usb_serial *serial)
|
|||
"%s: please contact support@connecttech.com\n",
|
||||
serial->type->description);
|
||||
kfree(result);
|
||||
kfree(command);
|
||||
return -ENODEV;
|
||||
|
||||
no_command_private:
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user