aboutsummaryrefslogtreecommitdiff
path: root/init.d.misc/wpa_supplicant.in
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2009-05-06 16:47:37 +0100
committerRoy Marples <roy@marples.name>2009-05-06 16:47:37 +0100
commit0aabe323755553cacd318944dbd495c5adebde12 (patch)
tree35f2e4f27297c0c06a8d63cb55cdd7a319776ad0 /init.d.misc/wpa_supplicant.in
parent7c81f74b60b9d15ed472f1ca63cab0a105a84c08 (diff)
Enable wpa_supplicant for >1 wireless interface if found.
Diffstat (limited to 'init.d.misc/wpa_supplicant.in')
-rw-r--r--init.d.misc/wpa_supplicant.in10
1 files changed, 6 insertions, 4 deletions
diff --git a/init.d.misc/wpa_supplicant.in b/init.d.misc/wpa_supplicant.in
index 8ee8de19..5a83ef16 100644
--- a/init.d.misc/wpa_supplicant.in
+++ b/init.d.misc/wpa_supplicant.in
@@ -3,9 +3,9 @@
# All rights reserved. Released under the 2-clause BSD license.
command=/usr/sbin/wpa_supplicant
-wpa_supplicant_conf=/etc/wpa_supplicant.conf
+: ${wpa_supplicant_conf:=/etc/wpa_supplicant.conf}
wpa_supplicant_if=${wpa_supplicant_if:+-i}$wpa_supplicant_if
-command_args="-B -c$wpa_supplicant_conf $wpa_supplicant_if"
+command_args="$wpa_supplicant_args -B -c$wpa_supplicant_conf $wpa_supplicant_if"
name="WPA Supplicant Daemon"
depend()
@@ -47,11 +47,13 @@ find_wireless()
append_wireless()
{
- local iface=
+ local iface= i=
iface=$(find_wireless)
if [ -n "$iface" ]; then
- command_args="$command_args -i$iface"
+ for i in $iface; do
+ command_args="$command_args -i$i"
+ done
else
eerror "Could not find a wireless interface"
fi