mirror of
https://github.com/php/php-src.git
synced 2024-11-27 11:53:33 +08:00
Cleanup: avoid useless array duplication
This commit is contained in:
parent
01d5beddf4
commit
c21d18ef95
@ -1674,12 +1674,10 @@ SPL_METHOD(Array, serialize)
|
||||
rebuild_object_properties(&intern->std);
|
||||
}
|
||||
|
||||
ZVAL_ARR(&members, zend_array_dup(intern->std.properties));
|
||||
ZVAL_ARR(&members, intern->std.properties);
|
||||
|
||||
php_var_serialize(&buf, &members, &var_hash); /* finishes the string */
|
||||
|
||||
zval_ptr_dtor(&members);
|
||||
|
||||
/* done */
|
||||
PHP_VAR_SERIALIZE_DESTROY(var_hash);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user