summaryrefslogtreecommitdiffstats
path: root/usr/local/www/diag_logs_dhcp.php
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@sullrich-MacBookPro.local>2009-03-31 22:51:32 -0400
committerScott Ullrich <sullrich@sullrich-MacBookPro.local>2009-03-31 22:51:32 -0400
commitd6abaa18c9c0cfdd3c8778897c5f407f34321d08 (patch)
treef3b95b1a5f9bedcf21741fcda3d76a69ba0e5c46 /usr/local/www/diag_logs_dhcp.php
parent568f30c2f897bffd08df28abb74b74cc2d8be2ad (diff)
downloadpfsense-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_dhcp.php')
-rwxr-xr-xusr/local/www/diag_logs_dhcp.php15
1 files changed, 2 insertions, 13 deletions
diff --git a/usr/local/www/diag_logs_dhcp.php b/usr/local/www/diag_logs_dhcp.php
index cdca3a2..07294cf 100755
--- a/usr/local/www/diag_logs_dhcp.php
+++ b/usr/local/www/diag_logs_dhcp.php
@@ -46,19 +46,8 @@ $nentries = $config['syslog']['nentries'];
if (!$nentries)
$nentries = 50;
-if ($_POST['clear']) {
- if(isset($config['system']['disablesyslogclog'])) {
- unlink($dhcpd_logfile);
- touch($dhcpd_logfile);
- } else {
-// exec("killall syslogd");
-// sleep(1);
-// if(file_exists("{$dhcpd_logfile}"))
-// unlink("{$dhcpd_logfile}");
- exec("/usr/sbin/fifolog_create -s 511488 {$dhcpd_logfile}");
- exec("/usr/bin/killall -HUP syslogd");
- }
-}
+if ($_POST['clear'])
+ clear_log_file($dhcpd_logfile);
$pgtitle = array("Status","System logs","DHCP");
include("head.inc");
OpenPOWER on IntegriCloud