Search Linux Wireless

[PATCH] rt61pci: rt61pci_beacon_update do not free skb twice

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The layer above will free the skb in an error case.

Signed-off-by: Daniel Wagner <wagi@xxxxxxxxx>
---
 drivers/net/wireless/rt2x00/rt61pci.c |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/drivers/net/wireless/rt2x00/rt61pci.c b/drivers/net/wireless/rt2x00/rt61pci.c
index 1cb056b..468a31c 100644
--- a/drivers/net/wireless/rt2x00/rt61pci.c
+++ b/drivers/net/wireless/rt2x00/rt61pci.c
@@ -2379,10 +2379,8 @@ static int rt61pci_beacon_update(struct ieee80211_hw *hw, struct sk_buff *skb,
 	 */
 	if (skb_headroom(skb) < intf->beacon->queue->desc_size) {
 		if (pskb_expand_head(skb, intf->beacon->queue->desc_size,
-				     0, GFP_ATOMIC)) {
-			dev_kfree_skb(skb);
+				     0, GFP_ATOMIC))
 			return -ENOMEM;
-		}
 	}
 
 	/*
-- 
1.5.4.3

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux