diff options
author | Scott Ullrich <sullrich@sullrich-MacBookPro.local> | 2009-03-31 22:51:32 -0400 |
---|---|---|
committer | Scott Ullrich <sullrich@sullrich-MacBookPro.local> | 2009-03-31 22:51:32 -0400 |
commit | d6abaa18c9c0cfdd3c8778897c5f407f34321d08 (patch) | |
tree | f3b95b1a5f9bedcf21741fcda3d76a69ba0e5c46 /usr/local/www/diag_logs_auth.php | |
parent | 568f30c2f897bffd08df28abb74b74cc2d8be2ad (diff) | |
download | pfsense-d6abaa18c9c0cfdd3c8778897c5f407f34321d08.zip pfsense-d6abaa18c9c0cfdd3c8778897c5f407f34321d08.tar.gz |
* Add clear_log_file() function and reduce code reuse
* Use clear_log_file() instead of duplicated logic
Diffstat (limited to 'usr/local/www/diag_logs_auth.php')
-rwxr-xr-x | usr/local/www/diag_logs_auth.php | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/usr/local/www/diag_logs_auth.php b/usr/local/www/diag_logs_auth.php index 2c0c7ef..413e223 100755 --- a/usr/local/www/diag_logs_auth.php +++ b/usr/local/www/diag_logs_auth.php @@ -44,19 +44,8 @@ $nentries = $config['syslog']['nentries']; if (!$nentries) $nentries = 50; -if ($_POST['clear']) { - if(isset($config['system']['disablesyslogclog'])) { - unlink($portal_logfile); - touch($portal_logfile); - } else { -// exec("killall syslogd"); -/// sleep(1); -// if(file_exists("{$portal_logfile}")) -// unlink("{$portal_logfile}"); - exec("/usr/sbin/fifolog_create -s 511488 {$portal_logfile}"); - exec("/usr/bin/killall -HUP syslogd"); - } -} +if ($_POST['clear']) + clear_log_file($portal_logfile); $pgtitle = array("Status","System logs","Portal Auth"); include("head.inc"); |