aboutsummaryrefslogtreecommitdiffstats
path: root/config/snort
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2009-02-10 16:06:09 -0500
committerScott Ullrich <sullrich@pfsense.org>2009-02-10 16:06:09 -0500
commit5997acaddc55fdb83d208e9dd194949b0f876be1 (patch)
treecfdbd261ca68e5364b970ad1d0dca047a684d211 /config/snort
parent089d4947a20e5e6e1714369740265e9ae872687b (diff)
downloadpfsense-packages-5997acaddc55fdb83d208e9dd194949b0f876be1.tar.gz
pfsense-packages-5997acaddc55fdb83d208e9dd194949b0f876be1.tar.bz2
pfsense-packages-5997acaddc55fdb83d208e9dd194949b0f876be1.zip
Only mkdir if the directory does not exist
Diffstat (limited to 'config/snort')
-rw-r--r--config/snort/snort.inc3
1 files changed, 2 insertions, 1 deletions
diff --git a/config/snort/snort.inc b/config/snort/snort.inc
index 681d0568..c1c1a400 100644
--- a/config/snort/snort.inc
+++ b/config/snort/snort.inc
@@ -620,7 +620,8 @@ function extract_snort_rules_md5($tmpfname) {
$static_output = gettext("Extracting snort rules...");
update_all_status($static_output);
}
- mkdir("/usr/local/etc/snort/rules/");
+ if(!is_dir("/usr/local/etc/snort/rules/"))
+ mkdir("/usr/local/etc/snort/rules/");
$cmd = "/usr/bin/tar xzf {$tmpfname}/{$snort_filename} -C /usr/local/etc/snort/ rules/";
$handle = popen("{$cmd} 2>&1", 'r');
while(!feof($handle)) {