Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
--TEST-- Bug #70332 (Wrong behavior while returning reference on object) --FILE-- <?php fu..
Decoded Output download
--TEST--
Bug #70332 (Wrong behavior while returning reference on object)
--FILE--
<?php
function & test($arg) {
return $arg;
}
$arg = new Stdclass();
$arg->name = array();
test($arg)->name[1] = "xxxx";
print_r($arg);
?>
--EXPECT--
stdClass Object
(
[name] => Array
(
[1] => xxxx
)
)
Did this file decode correctly?
Original Code
--TEST--
Bug #70332 (Wrong behavior while returning reference on object)
--FILE--
<?php
function & test($arg) {
return $arg;
}
$arg = new Stdclass();
$arg->name = array();
test($arg)->name[1] = "xxxx";
print_r($arg);
?>
--EXPECT--
stdClass Object
(
[name] => Array
(
[1] => xxxx
)
)
Function Calls
None |
Stats
MD5 | b17a5db55d37939446a826cdb63ce034 |
Eval Count | 0 |
Decode Time | 97 ms |