blob: c62de68b96144169df85e40d24f614f3d2177283 [file] [log] [blame]
From f4907a96f2e0494b03c7447ae2f5aac20dab61f8 Mon Sep 17 00:00:00 2001
From: Michael-CY Lee <michael-cy.lee@mediatek.com>
Date: Fri, 1 Mar 2024 16:59:53 +0800
Subject: [PATCH 071/126] mtk: hostapd: prevent getting non-MLD STA for other
links
Signed-off-by: Michael-CY Lee <michael-cy.lee@mediatek.com>
---
src/ap/sta_info.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/ap/sta_info.c b/src/ap/sta_info.c
index ea34d347f..44d98d5e0 100644
--- a/src/ap/sta_info.c
+++ b/src/ap/sta_info.c
@@ -87,7 +87,8 @@ struct sta_info * ap_get_sta(struct hostapd_data *hapd, const u8 *sta)
for (s = h->sta_list; s; s = s->next)
if ((!os_memcmp(s->setup_link_addr, sta, 6) ||
!os_memcmp(s->addr, sta, 6)) &&
- s->flags & WLAN_STA_ASSOC)
+ s->flags & WLAN_STA_ASSOC &&
+ s->mld_info.mld_sta)
return s;
}
}
--
2.18.0