* [patch 4/7] drivers/bluetooth/btsdio.c: fix double-free
@ 2008-02-05 7:48 akpm
2008-02-05 11:09 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: akpm @ 2008-02-05 7:48 UTC (permalink / raw)
To: marcel; +Cc: netdev, akpm, bunk
From: Adrian Bunk <bunk@kernel.org>
This patch fixes a double-free spotted by the Coverity checker.
Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-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);
_
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-02-05 11:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-02-05 7:48 [patch 4/7] drivers/bluetooth/btsdio.c: fix double-free akpm
2008-02-05 11:09 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox