summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2005-11-19 23:26:32 +0000
committerScott Ullrich <sullrich@pfsense.org>2005-11-19 23:26:32 +0000
commit191a81751647567956acba1154615f6c947f10fe (patch)
tree4283c84018aedfdced70713fbc61721891427c6e /etc
parenteb7370b8fb7c6b9cbfbf86de52655772adfe8a67 (diff)
downloadpfsense-191a81751647567956acba1154615f6c947f10fe.zip
pfsense-191a81751647567956acba1154615f6c947f10fe.tar.gz
MFC 7836 - Minor nitpicks
* Surround all variables within "" with {} * Output the command we are running for athctrl.sh
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/interfaces.inc27
1 files changed, 15 insertions, 12 deletions
diff --git a/etc/inc/interfaces.inc b/etc/inc/interfaces.inc
index aaba0b7..f6a3f73 100644
--- a/etc/inc/interfaces.inc
+++ b/etc/inc/interfaces.inc
@@ -481,7 +481,8 @@ function interfaces_wireless_configure($if, $wlcfg) {
$distance = escapeshellarg($wlcfg['distance']);
/* Set ssid */
- $ssid = ("ssid " . escapeshellarg($wlcfg['ssid']));
+ if($wlcfg['ssid'])
+ $ssid = "ssid " . escapeshellarg($wlcfg['ssid']);
/* Set stationname */
if ($wlcfg['stationname'])
@@ -578,7 +579,7 @@ EOD;
fwrite($fd, "{$wpa}");
fclose($fd);
- mwexec("$killall wpa_supplicant");
+ mwexec("{$killall} wpa_supplicant");
}
break;
@@ -617,21 +618,17 @@ EOD;
fwrite($fd, "{$wpa}");
fclose($fd);
- mwexec("$killall hostapd");
+ mwexec("{$killall} hostapd");
}
break;
case 'adhoc':
- mwexec("$killall hostapd");
- mwexec("$killall wpa_supplicant");
+ mwexec("{$killall} hostapd");
+ mwexec("{$killall} wpa_supplicant");
break;
}
/* all variables are set, lets start up everything */
-
- /* set ack timers according to users preference (if he has any) */
- if($distance)
- mwexec("/sbin/athctrl.sh -i {$if} -d {$distance}");
mwexec("$ifconfig $if" . " -mediaopt hostap,turbo"); // Fix bug with turbomode and reboot (hopefully)
mwexec("$ifconfig $if" . " down");
@@ -655,11 +652,17 @@ EOD;
if (isset($wlcfg['wpa']['enable'])) {
if ($wlcfg['mode'] == bss)
- mwexec("$wpa_supplicant -B -i {$if} -c {$g['varetc_path']}/wpa_supplicant_{$if}.conf");
+ mwexec("{$wpa_supplicant} -B -i {$if} -c {$g['varetc_path']}/wpa_supplicant_{$if}.conf");
if ($wlcfg['mode'] == hostap)
- mwexec("$hostapd -B {$g['varetc_path']}/hostapd_{$if}.conf");
+ mwexec("{$hostapd} -B {$g['varetc_path']}/hostapd_{$if}.conf");
}
-
+
+ /* set ack timers according to users preference (if he/she has any) */
+ if($distance) {
+ mwexec("/sbin/athctrl.sh -i {$if} -d {$distance}");
+ mwexec("echo /sbin/athctrl.sh -i {$if} -d {$distance} >/tmp/athctrl.txt");
+ }
+
if(isset($wlcfg['useolsr']))
setup_wireless_olsr($if);
OpenPOWER on IntegriCloud