summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--etc/inc/captiveportal.inc4
-rw-r--r--etc/inc/filter.inc4
-rw-r--r--etc/inc/vpn.inc4
3 files changed, 9 insertions, 3 deletions
diff --git a/etc/inc/captiveportal.inc b/etc/inc/captiveportal.inc
index 2582ea0..cf287e4 100644
--- a/etc/inc/captiveportal.inc
+++ b/etc/inc/captiveportal.inc
@@ -1024,9 +1024,11 @@ function captiveportal_allowedhostname_configure() {
if (isvalidpid("{$g['varrun_path']}/filterdns-{$cpzone}-cpah.pid"))
sigkillbypid("{$g['varrun_path']}/filterdns-{$cpzone}-cpah.pid", "HUP");
else {
- killbypid("{$g['varrun_path']}/filterdns-{$cpzone}-cpah.pid");
mwexec("/usr/local/sbin/filterdns -p {$g['varrun_path']}/filterdns-{$cpzone}-cpah.pid -i 300 -c {$cp_filterdns_filename} -y {$cpzone} -d 1");
}
+ } else {
+ killbypid("{$g['varrun_path']}/filterdns-{$cpzone}-cpah.pid");
+ @unlink("{$g['varrun_path']}/filterdns-{$cpzone}-cpah.pid");
}
return $rules;
diff --git a/etc/inc/filter.inc b/etc/inc/filter.inc
index 39f3ea7..5630bf9 100644
--- a/etc/inc/filter.inc
+++ b/etc/inc/filter.inc
@@ -337,13 +337,15 @@ function filter_configure_sync($delete_states_if_needed = true) {
if (isvalidpid("{$g['varrun_path']}/filterdns.pid"))
sigkillbypid("{$g['varrun_path']}/filterdns.pid", "HUP");
else {
- killbypid("{$g['varrun_path']}/filterdns.pid");
/*
* FilterDNS has three debugging levels. The default choosen is 1.
* Availabe are level 2 and greater then 2.
*/
mwexec("/usr/local/sbin/filterdns -p {$g['varrun_path']}/filterdns.pid -i 300 -c {$g['varetc_path']}/filterdns.conf -d 1");
}
+ } else {
+ killbypid("{$g['varrun_path']}/filterdns.pid");
+ @unlink("{$g['varrun_path']}/filterdns.pid");
}
/* run items scheduled for after filter configure run */
diff --git a/etc/inc/vpn.inc b/etc/inc/vpn.inc
index c890382..75fa74c 100644
--- a/etc/inc/vpn.inc
+++ b/etc/inc/vpn.inc
@@ -980,9 +980,11 @@ EOD;
if (isvalidpid("{$g['varrun_path']}/filterdns-ipsec.pid"))
sigkillbypid("{$g['varrun_path']}/filterdns-ipsec.pid", "HUP");
else {
- killbypid("{$g['varrun_path']}/filterdns-ipsec.pid");
mwexec("/usr/local/sbin/filterdns -p {$g['varrun_path']}/filterdns-ipsec.pid -i {$interval} -c {$g['varetc_path']}/ipsec/filterdns-ipsec.hosts -d 1");
}
+ } else {
+ killbypid("{$g['varrun_path']}/filterdns-ipsec.pid");
+ @unlink("{$g['varrun_path']}/filterdns-ipsec.pid");
}
vpn_ipsec_failover_configure();
OpenPOWER on IntegriCloud