mirror of
https://github.com/php/php-src.git
synced 2024-09-22 10:27:25 +00:00
Initialize with length instead of 0 (and thanks Antony for finding)
This commit is contained in:
parent
e58b49fc4c
commit
0cc9f01212
@ -2298,7 +2298,7 @@ PHP_FUNCTION(array_splice)
|
||||
/* Don't create the array of removed elements if it's not going
|
||||
* to be used; e.g. only removing and/or replacing elements */
|
||||
if (return_value_used) {
|
||||
int size = 0;
|
||||
int size = length;
|
||||
|
||||
/* Clamp the offset.. */
|
||||
if (offset > num_in) {
|
||||
|
Loading…
Reference in New Issue
Block a user