mirror of
https://github.com/php/php-src.git
synced 2024-09-22 10:27:25 +00:00
19 lines
313 B
PHP
19 lines
313 B
PHP
--TEST--
|
|
Bug #78612 (strtr leaks memory when integer keys are used and the subject string shorter).
|
|
--FILE--
|
|
<?php
|
|
|
|
$find_replace = array();
|
|
$_a = 7111222333000001;
|
|
$_b = 5000001;
|
|
|
|
for ($j=0; $j<10; $j++) {
|
|
$find_replace[$_a + $j] = $_b + $j;
|
|
}
|
|
|
|
echo strtr('Hello', $find_replace), "\n";
|
|
|
|
?>
|
|
--EXPECT--
|
|
Hello
|