mirror of
https://github.com/php/php-src.git
synced 2026-04-21 23:18:13 +02:00
f8ec5a1d4c
We shouldn't switch from range to no range for ZEND_DIV and instead explicitly return an overflowing range. Otherwise the range will not actually get updated during widening, and we'll perform essentially infinite narrowing. Fixes oss-fuzz #40566.
17 lines
181 B
PHP
17 lines
181 B
PHP
--TEST--
|
|
Range inference should not hang
|
|
--FILE--
|
|
<?php
|
|
|
|
function test() {
|
|
$a = 0;
|
|
while (true) {
|
|
$a = $a+!$a=$a/!!~$a;
|
|
}
|
|
}
|
|
|
|
?>
|
|
===DONE===
|
|
--EXPECT--
|
|
===DONE===
|