aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--packages/p3scan-pf/p3scan-pf.inc3
1 files changed, 2 insertions, 1 deletions
diff --git a/packages/p3scan-pf/p3scan-pf.inc b/packages/p3scan-pf/p3scan-pf.inc
index e35e8a36..599f5650 100644
--- a/packages/p3scan-pf/p3scan-pf.inc
+++ b/packages/p3scan-pf/p3scan-pf.inc
@@ -311,7 +311,8 @@ EOD;
mwexec("/usr/local/etc/rc.d/030.p3scan.sh stop");
/* test whether a pid file still exists and remove it if necessary */
- unlink_if_exists("/var/run/p3scan/p3scan.pid");
+ if (! is_service_running("p3scan-pf"))
+ unlink_if_exists("/var/run/p3scan/p3scan.pid");
mwexec("/usr/local/etc/rc.d/030.p3scan.sh start");
return 0;