[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <200802050747.m157lvnE010455@imap1.linux-foundation.org>
Date: Mon, 04 Feb 2008 23:48:16 -0800
From: akpm@...ux-foundation.org
To: marcel@...tmann.org
Cc: netdev@...r.kernel.org, akpm@...ux-foundation.org, bunk@...nel.org
Subject: [patch 4/7] drivers/bluetooth/btsdio.c: fix double-free
From: Adrian Bunk <bunk@...nel.org>
This patch fixes a double-free spotted by the Coverity checker.
Signed-off-by: Adrian Bunk <bunk@...nel.org>
Signed-off-by: Andrew Morton <akpm@...ux-foundation.org>
---
drivers/bluetooth/btsdio.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff -puN drivers/bluetooth/btsdio.c~drivers-bluetooth-btsdioc-fix-double-free drivers/bluetooth/btsdio.c
--- a/drivers/bluetooth/btsdio.c~drivers-bluetooth-btsdioc-fix-double-free
+++ a/drivers/bluetooth/btsdio.c
@@ -162,10 +162,8 @@ static int btsdio_rx_packet(struct btsdi
bt_cb(skb)->pkt_type = hdr[3];
err = hci_recv_frame(skb);
- if (err < 0) {
- kfree(skb);
+ if (err < 0)
return err;
- }
sdio_writeb(data->func, 0x00, REG_PC_RRT, NULL);
_
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists