aboutsummaryrefslogtreecommitdiffstats
path: root/config/unbound
diff options
context:
space:
mode:
Diffstat (limited to 'config/unbound')
-rw-r--r--config/unbound/unbound.inc4
1 files changed, 3 insertions, 1 deletions
diff --git a/config/unbound/unbound.inc b/config/unbound/unbound.inc
index afb3c0b7..76c35277 100644
--- a/config/unbound/unbound.inc
+++ b/config/unbound/unbound.inc
@@ -199,8 +199,10 @@ function unbound_control($action) {
if(!is_service_running("unbound"))
unbound_ctl_exec("start");
/* Link dnsmasq.pid to prevent dhcpleases logging error */
- if (!file_exists("/var/run/dnsmasq.pid"))
+ if (!is_link("/var/run/dnsmasq.pid")) {
+ @unlink("/var/run/dnsmasq.pid");
mwexec("/bin/ln -s /var/run/unbound.pid /var/run/dnsmasq.pid");
+ }
fetch_root_hints();
}
break;