diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2006-03-10 22:30:18 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2006-03-10 22:30:18 +0000 |
commit | 4d34bd4a2208a504b782e55f5906b8124444e5b4 (patch) | |
tree | 88062bd87bf45c8147d776b6afb3ca578cea5b29 /usr/local/www/diag_dhcp_leases.php | |
parent | 40825bb0577b79bb291281ae6c97a2dc09617b54 (diff) | |
download | pfsense-4d34bd4a2208a504b782e55f5906b8124444e5b4.zip pfsense-4d34bd4a2208a504b782e55f5906b8124444e5b4.tar.gz |
MFC 10444
Better diag_dhcp_leases online fix. grep for the active IP address to make sure it's active and we return just 1 result instead.
Diffstat (limited to 'usr/local/www/diag_dhcp_leases.php')
-rwxr-xr-x | usr/local/www/diag_dhcp_leases.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr/local/www/diag_dhcp_leases.php b/usr/local/www/diag_dhcp_leases.php index 67a357f..b3b0338 100755 --- a/usr/local/www/diag_dhcp_leases.php +++ b/usr/local/www/diag_dhcp_leases.php @@ -127,7 +127,7 @@ while ($data = array_shift($return)) { if ($d[0] == "ethernet") { $d = array_shift($return); $leases[$i]['mac'] = $d[0]; - $online = exec("/usr/sbin/arp -an |/usr/bin/grep {$d[0]}| /usr/bin/wc -l|/usr/bin/awk '{print $1;}'"); + $online = exec("/usr/sbin/arp -an |/usr/bin/grep {$d[0]}| grep {$leases[$i]['ip']}| /usr/bin/wc -l|/usr/bin/awk '{print $1;}'"); if ($online == 1) { $leases[$i]['online'] = 'online'; } else { |