Merge pull request #2719 from SaaldjorMike/del-utime-func

Replaced custom utime() function with microtime(true)
This commit is contained in:
Neil Lathwood
2016-01-10 22:43:31 +00:00
8 changed files with 14 additions and 29 deletions

View File

@@ -135,7 +135,7 @@ function poll_device($device, $options) {
$status = 0;
unset($array);
$device_start = utime();
$device_start = microtime(true);
// Start counting device poll time
echo $device['hostname'].' '.$device['device_id'].' '.$device['os'].' ';
if ($config['os'][$device['os']]['group']) {
@@ -253,7 +253,7 @@ function poll_device($device, $options) {
}
}//end if
$device_end = utime();
$device_end = microtime(true);
$device_run = ($device_end - $device_start);
$device_time = substr($device_run, 0, 5);