diff options
author | Scott Ullrich <sullrich@sullrich-MacBookPro.local> | 2009-03-18 19:46:24 -0400 |
---|---|---|
committer | Scott Ullrich <sullrich@sullrich-MacBookPro.local> | 2009-03-18 19:46:24 -0400 |
commit | 783cdcaaa733a4415eeaea21309b0437602b3929 (patch) | |
tree | 228fc62f36d17da41d7ffedd9c5b2661734fe4e0 /usr/local/www/diag_logs_auth.php | |
parent | 3d5b2e45e7a3d0ad6ae7dc59345283e626f675d2 (diff) | |
download | pfsense-783cdcaaa733a4415eeaea21309b0437602b3929.zip pfsense-783cdcaaa733a4415eeaea21309b0437602b3929.tar.gz |
* Rm log file before fifolog_create if it exists
* Do not hard code path to logs
Diffstat (limited to 'usr/local/www/diag_logs_auth.php')
-rwxr-xr-x | usr/local/www/diag_logs_auth.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/usr/local/www/diag_logs_auth.php b/usr/local/www/diag_logs_auth.php index 775419a..2c48e42 100755 --- a/usr/local/www/diag_logs_auth.php +++ b/usr/local/www/diag_logs_auth.php @@ -36,7 +36,6 @@ ##|*MATCH=diag_logs_auth.php* ##|-PRIV - require("guiconfig.inc"); $portal_logfile = "{$g['varlog_path']}/portalauth.log"; @@ -50,6 +49,9 @@ if ($_POST['clear']) { unlink($portal_logfile); touch($portal_logfile); } else { + exec("killall syslogd"); + if(file_exists("{$portal_logfile}")) + unlink_file("{$portal_logfile}"); exec("/usr/sbin/fifolog_create -s 511488 {$portal_logfile}"); } } |