diff --git a/discovery.php b/discovery.php index 02a1a0c70b..5dc6ff8dea 100755 --- a/discovery.php +++ b/discovery.php @@ -20,7 +20,7 @@ require 'includes/definitions.inc.php'; require 'includes/functions.php'; require 'includes/discovery/functions.inc.php'; -$start = utime(); +$start = microtime(true); $runtime_stats = array(); $sqlparams = array(); $options = getopt('h:m:i:n:d::a::q',array('os:','type:')); @@ -129,7 +129,7 @@ foreach (dbFetch("SELECT * FROM `devices` WHERE status = 1 AND disabled = 0 $whe discover_device($device, $options); } -$end = utime(); +$end = microtime(true); $run = ($end - $start); $proctime = substr($run, 0, 5); diff --git a/html/graph.php b/html/graph.php index 537c5e999a..99c53bd29d 100644 --- a/html/graph.php +++ b/html/graph.php @@ -12,15 +12,7 @@ */ -function utime() { - $time = explode(' ', microtime()); - $usec = (double) $time[0]; - $sec = (double) $time[1]; - return ($sec + $usec); - -} - -$start = utime(); +$start = microtime(true); require_once 'Net/IPv4.php'; @@ -54,7 +46,7 @@ require 'includes/graphs/graph.inc.php'; $console_color = new Console_Color2(); -$end = utime(); +$end = microtime(true); $run = ($end - $start); diff --git a/html/index.php b/html/index.php index 2f068860f0..46164c663b 100644 --- a/html/index.php +++ b/html/index.php @@ -72,7 +72,7 @@ $config['memcached']['ttl'] = $config['time']['now']+300; Plugins::start(); -$runtime_start = utime(); +$runtime_start = microtime(true); ob_start(); @@ -263,7 +263,7 @@ else {