Commit 84b8a97c authored by Joe Nardelli's avatar Joe Nardelli Committed by Greg Kroah-Hartman

[PATCH] USB: fix Memory leak in visor.c and ftdi_sio.c

Signed-off-by: default avatarJoe Nardelli <jnardelli@infosciences.com>
Signed-off-by: default avatarGreg Kroah-Hartman <greg@kroah.com>
parent 9425c727
......@@ -1504,6 +1504,7 @@ static int ftdi_write (struct usb_serial_port *port, int from_user,
if (status) {
err("%s - failed submitting write urb, error %d", __FUNCTION__, status);
count = status;
kfree (buffer);
}
/* we are done with this urb, so let the host driver
......
......@@ -518,6 +518,7 @@ static int visor_write (struct usb_serial_port *port, int from_user, const unsig
dev_err(&port->dev, "%s - usb_submit_urb(write bulk) failed with status = %d\n",
__FUNCTION__, status);
count = status;
kfree (buffer);
} else {
bytes_out += count;
}
......
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