aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2013-01-23 20:12:14 +0100
committerErmal <eri@pfsense.org>2013-01-23 20:12:14 +0100
commitc94259340f341e532246c415e93158f02f3b5f0a (patch)
treec3a3deb47de6c8579aa3c11969cc46264d0589e7
parent263d06b749c35c7af4a1da476c291b353cb85a28 (diff)
downloadpfsense-packages-c94259340f341e532246c415e93158f02f3b5f0a.tar.gz
pfsense-packages-c94259340f341e532246c415e93158f02f3b5f0a.tar.bz2
pfsense-packages-c94259340f341e532246c415e93158f02f3b5f0a.zip
Prevent errors from missing files Reported-by: http://forum.pfsense.org/index.php/topic,51493.msg310252.html#msg310252
-rwxr-xr-xconfig/snort/snort.inc3
1 files changed, 3 insertions, 0 deletions
diff --git a/config/snort/snort.inc b/config/snort/snort.inc
index d7db399e..cd76db6f 100755
--- a/config/snort/snort.inc
+++ b/config/snort/snort.inc
@@ -944,6 +944,9 @@ function snort_load_rules_map($rules_path) {
/* Read the file contents into an array, skipping */
/* empty lines. */
+ if (!file_exists($file))
+ continue;
+
$rules_array = file($file, FILE_SKIP_EMPTY_LINES);
$record = "";
$b_Multiline = false;