summaryrefslogtreecommitdiff
path: root/ext/standard/tests/strings/bug78612.phpt
blob: 7dad605e80d0b07fbbb9d2484662858348411c29 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
--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