aboutsummaryrefslogtreecommitdiffstats
path: root/package/hostapd/files/wpa_supplicant.sh
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2013-05-21 11:56:27 +0000
committerFelix Fietkau <nbd@openwrt.org>2013-05-21 11:56:27 +0000
commitb4fe48f75e7530d81cb90e58bc003fb655c036aa (patch)
tree684da747e1c52cc3d260a716bb26e1a94f602f33 /package/hostapd/files/wpa_supplicant.sh
parent56130bc5a8469bda1963b134a2bdeec7588b5a28 (diff)
downloadupstream-b4fe48f75e7530d81cb90e58bc003fb655c036aa.tar.gz
upstream-b4fe48f75e7530d81cb90e58bc003fb655c036aa.tar.bz2
upstream-b4fe48f75e7530d81cb90e58bc003fb655c036aa.zip
hostapd: sync with trunk r36533
Signed-off-by: Felix Fietkau <nbd@openwrt.org> git-svn-id: svn://svn.openwrt.org/openwrt/branches/attitude_adjustment@36682 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/hostapd/files/wpa_supplicant.sh')
-rw-r--r--package/hostapd/files/wpa_supplicant.sh7
1 files changed, 5 insertions, 2 deletions
diff --git a/package/hostapd/files/wpa_supplicant.sh b/package/hostapd/files/wpa_supplicant.sh
index cdca9b5539..0b5e1d391f 100644
--- a/package/hostapd/files/wpa_supplicant.sh
+++ b/package/hostapd/files/wpa_supplicant.sh
@@ -106,7 +106,7 @@ wpa_supplicant_setup_vif() {
config_get password "$vif" password
phase2="phase2=\"auth=${auth:-MSCHAPV2}\""
identity="identity=\"$identity\""
- password="password=\"$password\""
+ password="${password:+password=\"$password\"}"
;;
esac
eap_type="eap=$(echo $eap_type | tr 'a-z' 'A-Z')"
@@ -186,6 +186,9 @@ network={
$wep_tx_keyidx
}
EOF
- [ -z "$proto" -a "$key_mgmt" != "NONE" ] || \
+ if [ -n "$proto" -o "$key_mgmt" == "NONE" ]; then
wpa_supplicant ${bridge:+ -b $bridge} -B -P "/var/run/wifi-${ifname}.pid" -D ${driver:-wext} -i "$ifname" -c /var/run/wpa_supplicant-$ifname.conf $options
+ else
+ return 0
+ fi
}