diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/mwifiex/scan.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/wireless/mwifiex/scan.c b/drivers/net/wireless/mwifiex/scan.c index dae8dbb24a03..8a3f9598ad33 100644 --- a/drivers/net/wireless/mwifiex/scan.c +++ b/drivers/net/wireless/mwifiex/scan.c | |||
@@ -1469,7 +1469,7 @@ mwifiex_update_curr_bss_params(struct mwifiex_private *priv, u8 *bssid, | |||
1469 | s32 rssi, const u8 *ie_buf, size_t ie_len, | 1469 | s32 rssi, const u8 *ie_buf, size_t ie_len, |
1470 | u16 beacon_period, u16 cap_info_bitmap, u8 band) | 1470 | u16 beacon_period, u16 cap_info_bitmap, u8 band) |
1471 | { | 1471 | { |
1472 | struct mwifiex_bssdescriptor *bss_desc = NULL; | 1472 | struct mwifiex_bssdescriptor *bss_desc; |
1473 | int ret; | 1473 | int ret; |
1474 | unsigned long flags; | 1474 | unsigned long flags; |
1475 | u8 *beacon_ie; | 1475 | u8 *beacon_ie; |
@@ -1484,6 +1484,7 @@ mwifiex_update_curr_bss_params(struct mwifiex_private *priv, u8 *bssid, | |||
1484 | 1484 | ||
1485 | beacon_ie = kmemdup(ie_buf, ie_len, GFP_KERNEL); | 1485 | beacon_ie = kmemdup(ie_buf, ie_len, GFP_KERNEL); |
1486 | if (!beacon_ie) { | 1486 | if (!beacon_ie) { |
1487 | kfree(bss_desc); | ||
1487 | dev_err(priv->adapter->dev, " failed to alloc beacon_ie\n"); | 1488 | dev_err(priv->adapter->dev, " failed to alloc beacon_ie\n"); |
1488 | return -ENOMEM; | 1489 | return -ENOMEM; |
1489 | } | 1490 | } |