From 6e4e1f3d0b14a0c631cfde84fc9ad296dd6c367f Mon Sep 17 00:00:00 2001 From: ShevAbam Date: Tue, 11 Nov 2014 15:28:05 +0100 Subject: Add favicon ; change measurements ; fix on ping module --- libs/Utils/Misc.class.php | 2 +- libs/ping.php | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) (limited to 'libs') diff --git a/libs/Utils/Misc.class.php b/libs/Utils/Misc.class.php index 3fcfedb..d77bbf5 100644 --- a/libs/Utils/Misc.class.php +++ b/libs/Utils/Misc.class.php @@ -17,7 +17,7 @@ class Misc break; } - return round($filesize, $precision).' '.$units[$idUnit].'o'; + return round($filesize, $precision).' '.$units[$idUnit].'B'; } diff --git a/libs/ping.php b/libs/ping.php index 1cadb70..9ea0ec8 100644 --- a/libs/ping.php +++ b/libs/ping.php @@ -14,6 +14,11 @@ foreach ($hosts as $host) { exec('/bin/ping -qc 1 '.$host.' | awk -F/ \'/^rtt/ { print $5 }\'', $result); + if (!isset($result[0])) + { + $result[0] = 0; + } + $datas[] = array( 'host' => $host, 'ping' => $result[0], -- cgit v1.2.3