Skip to content

Commit

Permalink
USB: kl5usb105: fix memory leak
Browse files Browse the repository at this point in the history
Private data was not freed on error path in startup.

Cc: stable <stable@kernel.org>
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Johan Hovold authored and Greg Kroah-Hartman committed May 20, 2010
1 parent d733cec commit 313b0d8
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/usb/serial/kl5kusb105.c
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,7 @@ static int klsi_105_startup(struct usb_serial *serial)
usb_free_urb(priv->write_urb_pool[j]);
}
}
kfree(priv);
usb_set_serial_port_data(serial->port[i], NULL);
}
return -ENOMEM;
Expand Down

0 comments on commit 313b0d8

Please sign in to comment.