diff --git a/Core/Daemon.php b/Core/Daemon.php index a18852d..7039b15 100755 --- a/Core/Daemon.php +++ b/Core/Daemon.php @@ -791,13 +791,13 @@ private function dump() $out = ''; switch(true) { case $seconds > $d: - $out .= intval($seconds / $d) . 'd '; + $out .= (int)($seconds / $d) . 'd '; $seconds %= $d; case $seconds > $h: - $out .= intval($seconds / $h) . 'h '; + $out .= (int)($seconds / $h) . 'h '; $seconds %= $h; case $seconds > $m: - $out .= intval($seconds / $m) . 'm '; + $out .= (int)($seconds / $m) . 'm '; $seconds %= $m; default: $out .= "{$seconds}s"; diff --git a/Core/Lib/Memcache.php b/Core/Lib/Memcache.php index af3d8e3..03e2955 100755 --- a/Core/Lib/Memcache.php +++ b/Core/Lib/Memcache.php @@ -67,9 +67,9 @@ public function ns($namespace = null) public function getWithRetry($key, $flags = false, $timeout_override = false) { if ($timeout_override) - $max_tries = intval($timeout_override / 0.10); + $max_tries = (int)($timeout_override / 0.10); else - $max_tries = intval($this->auto_retry_timeout / 0.10); + $max_tries = (int)($this->auto_retry_timeout / 0.10); if ($max_tries < 1) $max_tries = 1; @@ -97,7 +97,7 @@ public function getWithRetry($key, $flags = false, $timeout_override = false) public function set($key, $var, $flags = null, $expire = null) { if ($this->auto_retry) - $max_tries = intval($this->auto_retry_timeout / 0.10); + $max_tries = (int)($this->auto_retry_timeout / 0.10); else $max_tries = 1; diff --git a/Core/Worker/Mediator.php b/Core/Worker/Mediator.php index 900b7a5..b97fb5a 100644 --- a/Core/Worker/Mediator.php +++ b/Core/Worker/Mediator.php @@ -1056,7 +1056,7 @@ public function dump() { sort($status_data); if ($count = count($status_data)) { $mean = round(array_sum($status_data) / $count, 5); - $median = round($status_data[intval($count / 2)], 5); + $median = round($status_data[(int)($count / 2)], 5); } $out[] = sprintf('%s %s %s %s %s', str_pad(substr($method, 0, 20), 20, ' ', STR_PAD_RIGHT),