summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2005-09-08 21:41:35 +0000
committerScott Ullrich <sullrich@pfsense.org>2005-09-08 21:41:35 +0000
commitf9a5831e6782c0c5dfeed339325689e660f52871 (patch)
tree0b570e7ce0bcc8d471492787dc92a04e83e6790a /etc
parentdd462f3ead418f6733c32ba0b709caea2d7e7f7b (diff)
downloadpfsense-f9a5831e6782c0c5dfeed339325689e660f52871.zip
pfsense-f9a5831e6782c0c5dfeed339325689e660f52871.tar.gz
If hostapd is already running, -HUP it
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/interfaces.inc6
1 files changed, 5 insertions, 1 deletions
diff --git a/etc/inc/interfaces.inc b/etc/inc/interfaces.inc
index e0c7f47..b0540fb 100644
--- a/etc/inc/interfaces.inc
+++ b/etc/inc/interfaces.inc
@@ -480,7 +480,11 @@ EOD;
$fd = fopen("{$g['etc_path']}/hostapd_{$if}.conf", "w");
fwrite($fd, "{$wpa}");
fclose($fd);
- mwexec("/usr/sbin/hostapd -B {$g['etc_path']}/hostapd_{$if}.conf");
+ if(is_process_running("hostapd")) {
+ mwexec("/usr/bin/killall -HUP hostapd");
+ } else {
+ mwexec("/usr/sbin/hostapd -B {$g['etc_path']}/hostapd_{$if}.conf");
+ }
}
break;
OpenPOWER on IntegriCloud