diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2009-08-20 17:59:31 -0400 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2009-08-20 17:59:31 -0400 |
commit | f5200c44757b817a194d63aea45b874519279830 (patch) | |
tree | 46f1c24d8272df456a661ed66c635341af86472d /usr | |
parent | ed0b79491f43ee7c0e705256fbba1a6ac081942c (diff) | |
download | pfsense-f5200c44757b817a194d63aea45b874519279830.zip pfsense-f5200c44757b817a194d63aea45b874519279830.tar.gz |
Add missing debug checks
Diffstat (limited to 'usr')
-rwxr-xr-x | usr/local/www/firewall_aliases_edit.php | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/usr/local/www/firewall_aliases_edit.php b/usr/local/www/firewall_aliases_edit.php index 1aaec7e..80576d4 100755 --- a/usr/local/www/firewall_aliases_edit.php +++ b/usr/local/www/firewall_aliases_edit.php @@ -54,14 +54,15 @@ if($_POST) $origname = $_POST['origname']; // Debugging -exec("rm -f /tmp/print_r"); +if($debug) + exec("rm -f /tmp/print_r"); function update_alias_names_upon_change($section, $subsection, $fielda, $fieldb, $new_alias_name) { - global $config, $pconfig, $origname, $fd; + global $config, $pconfig, $origname, $debug; if(!$origname) return; - $fd = fopen("/tmp/print_r", "a"); + if($debug) $fd = fopen("/tmp/print_r", "a"); if($debug) fwrite($fd, print_r($pconfig, true)); if($fieldb) { @@ -83,7 +84,7 @@ function update_alias_names_upon_change($section, $subsection, $fielda, $fieldb, } } - fclose($fd); + if($debug) fclose($fd); } |