net/irda/mcs7780: fix memory leaks in mcs_net_open()
authorAlexey Khoroshilov <khoroshilov@ispras.ru>
Thu, 12 Sep 2013 20:51:20 +0000 (00:51 +0400)
committerDavid S. Miller <davem@davemloft.net>
Fri, 13 Sep 2013 03:43:56 +0000 (23:43 -0400)
commit8947312987e3d8b3457452c27d3bdacde9984f47
tree02a4b6c87c06ca57ec787527f3a08febefc1ae38
parent38463e2c290426262cd9a75fe66cbbe2925a68c2
net/irda/mcs7780: fix memory leaks in mcs_net_open()

If rx_urb allocation fails in mcs_setup_urbs(), tx_urb leaks.
If mcs_receive_start() fails in mcs_net_open(), the both urbs are not deallocated.

The patch fixes the issues and by the way fixes label indentation.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/irda/mcs7780.c