Skip to content

Commit b1b98e0

Browse files
committed
Make 045.phpt busy wait
The timeout is only real-time based on Windows. Make this use a busy wait loop instead. If hard_timeout is broken, this will fail with a run-tests enforced timeout instead.
1 parent 75470bc commit b1b98e0

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

tests/lang/045.phpt

+1-7
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,7 @@ set_time_limit(1);
1313
register_shutdown_function("plop");
1414

1515
function plop() {
16-
$ts = time();
17-
while(true) {
18-
if ((time()-$ts) > 2) {
19-
echo "Failed!";
20-
break;
21-
}
22-
}
16+
while (true);
2317
}
2418
plop();
2519
?>

0 commit comments

Comments
 (0)