mirror of
https://github.com/php/php-src.git
synced 2024-09-23 10:57:26 +00:00
ae3b2078ea
If php_strtr_array_prepare_repls() reports pattern_len == 0, we return early to avoid OOB accesses, and because there is nothing to replace anyway.
13 lines
164 B
PHP
13 lines
164 B
PHP
--TEST--
|
|
Bug #72823 (strtr out-of-bound access)
|
|
--FILE--
|
|
<?php
|
|
var_dump(
|
|
strtr(11, array('aaa' => 'bbb'))
|
|
);
|
|
?>
|
|
===DONE===
|
|
--EXPECT--
|
|
string(2) "11"
|
|
===DONE===
|