wifi: mt76: fix potential memory leak of beacon commands

Fix potential memory leak when setting beacon and inband discovery
commands.

Fixes: e57b790146 ("mt76: add mac80211 driver for MT7915 PCIe-based chipsets")
Fixes: 98686cd216 ("wifi: mt76: mt7996: add driver for MediaTek Wi-Fi 7 (802.11be) devices")
Signed-off-by: Bo Jiao <Bo.Jiao@mediatek.com>
Signed-off-by: Shayne Chen <shayne.chen@mediatek.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
This commit is contained in:
Bo Jiao 2023-08-31 14:22:16 +08:00 • committed by Felix Fietkau
commit d6a2f91741
2 changed files with 16 additions and 4 deletions