[PATCH] time/001.phpt fix

From: Date: Fri, 23 Jul 2004 21:17:15 +0000
Subject: [PATCH] time/001.phpt fix
Groups: php.internals 
Request: Send a blank email to internals+get-11524@lists.php.net to get a copy of this message
[resend] There's no reason why gettimeofday() shouldn''t return the same time in successive calls; this test fails spuriously on Linux/x86_64 (which has a particularly fast gettimeofday() implementation). --- ext/standard/tests/time/001.phpt 23 May 2003 20:56:33 -0000 1.4.2.2 +++ ext/standard/tests/time/001.phpt 16 Jul 2004 12:50:13 -0000 @@ -17,7 +17,7 @@ for ($i=1;$i<=100000;$i++) { list($micro,$time)=explode(" ",microtime()); - if ($time > $last_t || ($time == $last_t && $micro > $last_m)) { + if ($time > $last_t || ($time == $last_t && $micro >= $last_m)) { $passed++; } else if ($failed++ <=10) { $result .= sprintf('%06d', $i).": $time $micro < $last_t $last_m\n";

« previous php.internals (#11524) next »