aboutsummaryrefslogtreecommitdiffstats
path: root/package/network/services/hostapd/files
diff options
context:
space:
mode:
authorLeon M. George <leon@georgemail.eu>2021-01-12 10:30:08 +0100
committerAdrian Schmutzler <freifunk@adrianschmutzler.de>2021-01-15 18:17:45 +0100
commitd5bbd4975cbb6fbbfb57d183d1e03453d88f923d (patch)
tree89c47dbd72c514aaa38daf2691d119b194fe1434 /package/network/services/hostapd/files
parent218eff5bdbffbb92e222ba0183ae25220d2defe3 (diff)
downloadupstream-d5bbd4975cbb6fbbfb57d183d1e03453d88f923d.tar.gz
upstream-d5bbd4975cbb6fbbfb57d183d1e03453d88f923d.tar.bz2
upstream-d5bbd4975cbb6fbbfb57d183d1e03453d88f923d.zip
hostapd: fix setting wps_state to "not configured"
With encryption disabled, it was intended to set wpa_state=1 (enabled, not configured) through the 'wps_not_configured' flag. The flag is set appropriately but the condition using it is broken. Instead, 'wps_configured' is checked and wpa_state is always 2 (enabled, configured). Fix it by using the correct variable name. Fixes: 498d84fc4e00 ("netifd: add wireless configuration support and port mac80211 to the new framework") Signed-off-by: Leon M. George <leon@georgemail.eu> [commit title/message improvements] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Diffstat (limited to 'package/network/services/hostapd/files')
-rw-r--r--package/network/services/hostapd/files/hostapd.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/package/network/services/hostapd/files/hostapd.sh b/package/network/services/hostapd/files/hostapd.sh
index 815f22db74..45a49b8faa 100644
--- a/package/network/services/hostapd/files/hostapd.sh
+++ b/package/network/services/hostapd/files/hostapd.sh
@@ -666,7 +666,7 @@ hostapd_set_bss_options() {
set_default wps_independent 1
wps_state=2
- [ -n "$wps_configured" ] && wps_state=1
+ [ -n "$wps_not_configured" ] && wps_state=1
[ "$ext_registrar" -gt 0 -a -n "$network_bridge" ] && append bss_conf "upnp_iface=$network_bridge" "$N"