File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -90,20 +90,20 @@ static void php_intl_idn_to_46(INTERNAL_FUNCTION_PARAMETERS,
9090 ZSTR_VAL (buffer )[len ] = '\0' ;
9191 ZSTR_LEN (buffer ) = len ;
9292
93- if (info .errors == 0 ) {
94- RETVAL_STR_COPY (buffer );
95- } else {
96- RETVAL_FALSE ;
97- }
98-
9993 if (idna_info ) {
10094 add_assoc_str_ex (idna_info , "result" , sizeof ("result" )- 1 , zend_string_copy (buffer ));
10195 add_assoc_bool_ex (idna_info , "isTransitionalDifferent" ,
10296 sizeof ("isTransitionalDifferent" )- 1 , info .isTransitionalDifferent );
10397 add_assoc_long_ex (idna_info , "errors" , sizeof ("errors" )- 1 , (zend_long )info .errors );
10498 }
10599
106- zend_string_release (buffer );
100+ if (info .errors == 0 ) {
101+ RETVAL_STR (buffer );
102+ } else {
103+ zend_string_release_ex (buffer , false);
104+ RETVAL_FALSE ;
105+ }
106+
107107 uidna_close (uts46 );
108108}
109109
You can’t perform that action at this time.
0 commit comments