Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/pi-hole/pi-hole.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian König <ckoenig@posteo.de>2022-09-06 18:09:52 +0300
committerChristian König <ckoenig@posteo.de>2022-09-06 18:09:52 +0300
commit89b88416b363840e5a7afd72e9f0f5d65ddf5d3b (patch)
treead00e5e0b23c19f541ed4c2cda72f2a8b70ab12f
parent5d913ad1925bcc65ff32327b0eb270267f3b15e3 (diff)
Fix 4898
Signed-off-by: Christian König <ckoenig@posteo.de>
-rwxr-xr-xpihole6
1 files changed, 3 insertions, 3 deletions
diff --git a/pihole b/pihole
index eb825965..1047d152 100755
--- a/pihole
+++ b/pihole
@@ -104,6 +104,9 @@ restartDNS() {
local svcOption svc str output status pid icon FTL_PID_FILE
svcOption="${1:-restart}"
+ # get the current path to the pihole-FTL.pid
+ FTL_PID_FILE="$(getFTLPIDFile)"
+
# Determine if we should reload or restart
if [[ "${svcOption}" =~ "reload-lists" ]]; then
# Reloading of the lists has been requested
@@ -111,9 +114,6 @@ restartDNS() {
# Note 2: We cannot use killall here as it does
# not know about real-time signals
- # get the current path to the pihole-FTL.pid
- FTL_PID_FILE="$(getFTLPIDFile)"
-
pid="$(getFTLPID ${FTL_PID_FILE})"
if [[ "$pid" -eq "-1" ]]; then
svc="true"