@@ -480,9 +480,8 @@ static spl_filesystem_object *spl_filesystem_object_create_info(zend_string *fil
480480 RETVAL_OBJ (& intern -> std );
481481
482482 if (ce -> constructor -> common .scope != spl_ce_SplFileInfo ) {
483- ZVAL_STR_COPY (& arg1 , file_path );
483+ ZVAL_STR (& arg1 , file_path );
484484 zend_call_method_with_1_params (Z_OBJ_P (return_value ), ce , & ce -> constructor , "__construct" , NULL , & arg1 );
485- zval_ptr_dtor (& arg1 );
486485 } else {
487486 spl_filesystem_info_set_filename (intern , file_path );
488487 }
@@ -520,9 +519,8 @@ static spl_filesystem_object *spl_filesystem_object_create_type(int num_args, sp
520519 }
521520
522521 if (ce -> constructor -> common .scope != spl_ce_SplFileInfo ) {
523- ZVAL_STR_COPY (& arg1 , source -> file_name );
522+ ZVAL_STR (& arg1 , source -> file_name );
524523 zend_call_method_with_1_params (Z_OBJ_P (return_value ), ce , & ce -> constructor , "__construct" , NULL , & arg1 );
525- zval_ptr_dtor (& arg1 );
526524 } else {
527525 intern -> file_name = zend_string_copy (source -> file_name );
528526 intern -> path = spl_filesystem_object_get_path (source );
@@ -549,11 +547,9 @@ static spl_filesystem_object *spl_filesystem_object_create_type(int num_args, sp
549547 }
550548
551549 if (ce -> constructor -> common .scope != spl_ce_SplFileObject ) {
552- ZVAL_STR_COPY (& arg1 , source -> file_name );
553- ZVAL_STR_COPY (& arg2 , open_mode );
550+ ZVAL_STR (& arg1 , source -> file_name );
551+ ZVAL_STR (& arg2 , open_mode );
554552 zend_call_method_with_2_params (Z_OBJ_P (return_value ), ce , & ce -> constructor , "__construct" , NULL , & arg1 , & arg2 );
555- zval_ptr_dtor (& arg1 );
556- zval_ptr_dtor (& arg2 );
557553 } else {
558554 intern -> file_name = source -> file_name ;
559555 intern -> path = spl_filesystem_object_get_path (source );
0 commit comments