qca-wifi: Drop mgmt nbuf in tx_capture disabled case
If tx_capture is disabled, the frames notified to tx_capture
module needs to be freed.
This change frees mgmt frames in tx capture module, in case feature
is disabled
Change-Id: I71f102ba2f25f23bdcef63dddb525d5f7b0a692a
CRs-Fixed: 2643848
diff --git a/dp/wifi3.0/dp_tx_capture.c b/dp/wifi3.0/dp_tx_capture.c
index f78e92d..d70974c 100644
--- a/dp/wifi3.0/dp_tx_capture.c
+++ b/dp/wifi3.0/dp_tx_capture.c
@@ -418,6 +418,9 @@
"dlvr mgmt frm(0x%08x): fc 0x%x %x, dur 0x%x%x\n",
ptr_mgmt_hdr->ppdu_id, wh->i_fc[1], wh->i_fc[0],
wh->i_dur[1], wh->i_dur[0]);
+ } else {
+ qdf_nbuf_free(nbuf);
+ return;
}
}