Skip to content

Commit e2b94fd

Browse files
committed
[nrf noup] zephyr: Fix memory leak
nrf-squash! [nrf noup] zephyr: wifi: MBO Pre-certification bugfixes Free the MLME buffer once it's sent. Fixes SHEL-2738. Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
1 parent c947dc6 commit e2b94fd

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

src/drivers/driver_zephyr.c

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1603,9 +1603,16 @@ static int wpa_drv_zep_send_action(void *priv, unsigned int freq,
16031603
os_memcpy(hdr->addr3, bssid, ETH_ALEN);
16041604

16051605

1606-
return dev_ops->send_mlme(if_ctx->dev_priv, buf, 24 + data_len,
1606+
ret = dev_ops->send_mlme(if_ctx->dev_priv, buf, 24 + data_len,
16071607
0, freq, no_cck, 1,
16081608
wait_time, 0);
1609+
if (ret) {
1610+
wpa_printf(MSG_ERROR, "wpa_supp: Failed to send Action frame: %d", ret);
1611+
}
1612+
1613+
os_free(buf);
1614+
1615+
return ret;
16091616
}
16101617

16111618
static int nl80211_get_ext_capab(void *priv, enum wpa_driver_if_type type,

0 commit comments

Comments
 (0)