[IRDA]: mcs7780 needs to free allocated rx buffer.

While testing the mcs7780 based IrDA USB dongle I've stumbled upon
memory leak in mcs_net_close(). Patch below fixes it.

Signed-off-by: Hinko Kocevar <hinko.kocevar@cetrtapot.si>
Signed-off-by: Samuel Ortiz <samuel@sortiz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Hinko Kocevar 2007-12-16 14:08:22 -08:00 коммит произвёл David S. Miller
Родитель 497ba7f4c8
Коммит 0ff804348d
1 изменённых файлов: 2 добавлений и 0 удалений

Просмотреть файл

@ -677,6 +677,8 @@ static int mcs_net_close(struct net_device *netdev)
/* Stop transmit processing */
netif_stop_queue(netdev);
kfree_skb(mcs->rx_buff.skb);
/* kill and free the receive and transmit URBs */
usb_kill_urb(mcs->rx_urb);
usb_free_urb(mcs->rx_urb);