mirror of
https://github.com/php/php-src.git
synced 2025-08-15 13:38:49 +02:00
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.
This commit is contained in:
parent
75470bc312
commit
b1b98e08d0
1 changed files with 1 additions and 7 deletions
|
@ -13,13 +13,7 @@ set_time_limit(1);
|
|||
register_shutdown_function("plop");
|
||||
|
||||
function plop() {
|
||||
$ts = time();
|
||||
while(true) {
|
||||
if ((time()-$ts) > 2) {
|
||||
echo "Failed!";
|
||||
break;
|
||||
}
|
||||
}
|
||||
while (true);
|
||||
}
|
||||
plop();
|
||||
?>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue