jobcore/openresolv/fs33801.patch
2022-03-20 14:19:37 +02:00

32 lines
1.1 KiB
Diff

diff -u -r openresolv-3.8.1/dnsmasq.in openresolv-3.8.1-arch/dnsmasq.in
--- openresolv-3.8.1/dnsmasq.in 2016-05-19 12:36:35.000000000 +0200
+++ openresolv-3.8.1-arch/dnsmasq.in 2016-05-19 20:05:19.659940747 +0200
@@ -190,8 +190,8 @@
fi
fi
if $dbus; then
- if [ -s "$dnsmasq_pid" ]; then
- $changed || kill -HUP $(cat "$dnsmasq_pid")
+ if $changed && systemctl --quiet is-active dnsmasq; then
+ systemctl reload dnsmasq
fi
# Send even if empty so old servers are cleared
if $dbus_ex; then
diff -u -r openresolv-3.8.1/unbound.in openresolv-3.8.1-arch/unbound.in
--- openresolv-3.8.1/unbound.in 2016-05-19 12:36:35.000000000 +0200
+++ openresolv-3.8.1-arch/unbound.in 2016-05-19 20:04:20.207722679 +0200
@@ -86,12 +86,7 @@
[ "$(cat "$unbound_conf")" != "$(printf %s "$newconf")" ]
then
printf %s "$newconf" >"$unbound_conf"
- # If we can't sent a HUP then force a restart
- if [ -s "$unbound_pid" ]; then
- if ! kill -HUP $(cat "$unbound_pid") 2>/dev/null; then
- restart_unbound
- fi
- else
- restart_unbound
+ if systemctl --quiet is-active unbound; then
+ systemctl reload unbound
fi
fi