diff --git a/src/Hprose/Service.php b/src/Hprose/Service.php index 018df5e4..a9ce52d9 100644 --- a/src/Hprose/Service.php +++ b/src/Hprose/Service.php @@ -471,9 +471,9 @@ protected function doFunctionList() { $stream->close(); return $data; } - protected function delay($interval, $data) { - $seconds = floor($interval); - $nanoseconds = ($interval - $seconds) * 1000000000; + protected function delay($milliseconds, $data) { + $seconds = floor($milliseconds / 1000); + $nanoseconds = ($milliseconds % 1000) * 1000000; time_nanosleep($seconds, $nanoseconds); return Future\value($data); }