[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20071024162635.GM30533@stusta.de>
Date: Wed, 24 Oct 2007 18:26:35 +0200
From: Adrian Bunk <bunk@...nel.org>
To: David Vrabel <david.vrabel@....com>,
Marcel Holtmann <marcel@...tmann.org>, maxk@...lcomm.com
Cc: bluez-devel@...ts.sf.net, linux-kernel@...r.kernel.org
Subject: [2.6 patch] drivers/bluetooth/btsdio.c: fix double-free
This patch fixes a double-free spotted by the Coverity checker.
Signed-off-by: Adrian Bunk <bunk@...nel.org>
---
09bae986c340a634714517659822959cef72f66d
diff --git a/drivers/bluetooth/btsdio.c b/drivers/bluetooth/btsdio.c
index b786f61..58630cc 100644
--- a/drivers/bluetooth/btsdio.c
+++ b/drivers/bluetooth/btsdio.c
@@ -162,10 +162,8 @@ static int btsdio_rx_packet(struct btsdio_data *data)
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 linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists