can: j1939: fix resource leak of skb on error return paths
Currently the error return paths do not free skb and this results in a
memory leak. Fix this by freeing them before the return.
Addresses-Coverity: ("Resource leak")
Fixes: 9d71dd0c ("can: add support of SAE J1939 protocol")
Signed-off-by:
Colin Ian King <colin.king@canonical.com>
Acked-by:
Oleksij Rempel <o.rempel@pengutronix.de>
Signed-off-by:
Marc Kleine-Budde <mkl@pengutronix.de>
Loading
Please sign in to comment