]> git.baikalelectronics.ru Git - kernel.git/commit
can: gs_usb: gs_can_open(): prevent memory leak
authorNavid Emamdoost <navid.emamdoost@gmail.com>
Fri, 20 Sep 2019 02:44:38 +0000 (21:44 -0500)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Mon, 4 Nov 2019 20:47:20 +0000 (21:47 +0100)
commit073e7b3eab4c49ad514c8905a6fc38351c4d9eef
treebda3705945340f42c209771ad76652ba9e8e965e
parentaf3e28e65a57bea46a37dadc4fd45a7e9d1bcc09
can: gs_usb: gs_can_open(): prevent memory leak

In gs_can_open() if usb_submit_urb() fails the allocated urb should be
released.

Fixes: ff8e02f02963 ("can: gs_usb: Added support for the GS_USB CAN devices")
Cc: linux-stable <stable@vger.kernel.org>
Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/usb/gs_usb.c