[PATCH] Fix bss_is_ess() in case of an IBSS network

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The check for the ESS or IBSS bits in the BSS caps is done via equality
to IEEE80211_CAP_ESS (0x01). This will only be true for AP/ESS and will
fail in case of IBSS (0x02).
---
 wpa_supplicant/events.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/wpa_supplicant/events.c b/wpa_supplicant/events.c
index f28e4399e..c8208e53e 100644
--- a/wpa_supplicant/events.c
+++ b/wpa_supplicant/events.c
@@ -906,8 +906,7 @@ static int bss_is_ess(struct wpa_bss *bss)
 			IEEE80211_CAP_DMG_AP;
 	}
 
-	return ((bss->caps & (IEEE80211_CAP_ESS | IEEE80211_CAP_IBSS)) ==
-		IEEE80211_CAP_ESS);
+	return (bss->caps & IEEE80211_CAP_ESS || bss->caps & IEEE80211_CAP_IBSS);
 }
 
 
-- 
2.17.1


_______________________________________________
Hostap mailing list
Hostap@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/hostap



[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux