From 91177de593f263ff969a705485317a5b6960684a Mon Sep 17 00:00:00 2001 From: Daniel Stefan Haischt Date: Sat, 5 Aug 2006 03:48:13 +0000 Subject: - stop the service before deleting the package. --- packages/p3scan-pf/p3scan-pf.inc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/packages/p3scan-pf/p3scan-pf.inc b/packages/p3scan-pf/p3scan-pf.inc index 599f5650..294604d3 100644 --- a/packages/p3scan-pf/p3scan-pf.inc +++ b/packages/p3scan-pf/p3scan-pf.inc @@ -326,8 +326,10 @@ function custom_php_install_command() { function custom_php_deinstall_command() { global $config, $g; conf_mount_rw(); - unlink_if_exists("/usr/local/pkg/pf/p3scan_rules.php"); - unlink_if_exists("/usr/local/www/p3scan_rules.php"); + + if (is_service_running("p3scan-pf")) + stop_service("p3scan-pf"); + unlink_if_exists("/usr/local/etc/p3scan/p3scan.conf"); unlink_if_exists("/usr/local/etc/p3scan/p3scan.mail"); unlink_if_exists("/usr/local/etc/rc.d/030.p3scan.sh"); @@ -335,6 +337,7 @@ function custom_php_deinstall_command() { mwexec("rm -rf /var/spool/p3scan"); mwexec("rm -rf /var/run/p3scan"); mwexec("rm -rf /var/run/p3scan"); + conf_mount_ro(); } -- cgit v1.2.3