aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xconfig/snort/snort.inc4
-rw-r--r--config/snort/snort_post_install.php4
2 files changed, 4 insertions, 4 deletions
diff --git a/config/snort/snort.inc b/config/snort/snort.inc
index ca527b31..bf2af306 100755
--- a/config/snort/snort.inc
+++ b/config/snort/snort.inc
@@ -3011,7 +3011,7 @@ function snort_deinstall() {
mwexec('/usr/bin/killall -9 snort', true);
sleep(2);
// Delete any leftover snort PID files in /var/run
- unlink_if_exists("/var/run/snort_*.pid");
+ unlink_if_exists("{$g['varrun_path']}/snort_*.pid");
/* Make sure all active Barnyard2 processes are terminated */
/* Log a message only if a running process is detected */
@@ -3022,7 +3022,7 @@ function snort_deinstall() {
mwexec('/usr/bin/killall -9 barnyard2', true);
sleep(2);
// Delete any leftover barnyard2 PID files in /var/run
- unlink_if_exists("/var/run/barnyard2_*.pid");
+ unlink_if_exists("{$g['varrun_path']}/barnyard2_*.pid");
/* Remove our custom <service> entries from config */
$is_dirty = FALSE;
diff --git a/config/snort/snort_post_install.php b/config/snort/snort_post_install.php
index a7693f1a..bbdbe476 100644
--- a/config/snort/snort_post_install.php
+++ b/config/snort/snort_post_install.php
@@ -77,14 +77,14 @@ if(is_process_running("snort")) {
exec("/usr/bin/killall -z snort");
sleep(2);
// Delete any leftover snort PID files in /var/run
- unlink_if_exists("/var/run/snort_*.pid");
+ unlink_if_exists("{$g['varrun_path']}/snort_*.pid");
}
// Hard kill any running Barnyard2 processes
if(is_process_running("barnyard")) {
exec("/usr/bin/killall -z barnyard2");
sleep(2);
// Delete any leftover barnyard2 PID files in /var/run
- unlink_if_exists("/var/run/barnyard2_*.pid");
+ unlink_if_exists("{$g['varrun_path']}/barnyard2_*.pid");
}
/* Set flag for post-install in progress */