can: usb_8dev: Fix memory leak of priv->cmd_msg_buffer
authorMarc Kleine-Budde <mkl@pengutronix.de>
Thu, 2 Mar 2017 11:03:40 +0000 (12:03 +0100)
committerWilly Tarreau <w@1wt.eu>
Tue, 20 Jun 2017 12:03:12 +0000 (14:03 +0200)
commitd2ab6e524ffb26caf0680aaf2963082d26d2b77d
treee9c888f6353bd071c95ed50dfd62c1aff7517272
parentd5361ee850ef3e69a92883e46ccbb5ed6ccb9323
can: usb_8dev: Fix memory leak of priv->cmd_msg_buffer

commit 7c42631376306fb3f34d51fda546b50a9b6dd6ec upstream.

The priv->cmd_msg_buffer is allocated in the probe function, but never
kfree()ed. This patch converts the kzalloc() to resource-managed
kzalloc.

Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Willy Tarreau <w@1wt.eu>
drivers/net/can/usb/usb_8dev.c