@@ -3075,7 +3075,7 @@ MBSTRING_API HashTable *php_mb_convert_encoding_recursive(HashTable *input, cons
3075
3075
php_error_docref (NULL , E_WARNING , "Cannot convert recursively referenced values" );
3076
3076
return NULL ;
3077
3077
}
3078
- GC_PROTECT_RECURSION (input );
3078
+ GC_TRY_PROTECT_RECURSION (input );
3079
3079
output = zend_new_array (zend_hash_num_elements (input ));
3080
3080
ZEND_HASH_FOREACH_KEY_VAL (input , idx , key , entry ) {
3081
3081
/* convert key */
@@ -3120,7 +3120,7 @@ MBSTRING_API HashTable *php_mb_convert_encoding_recursive(HashTable *input, cons
3120
3120
zend_hash_index_add (output , idx , & entry_tmp );
3121
3121
}
3122
3122
} ZEND_HASH_FOREACH_END ();
3123
- GC_UNPROTECT_RECURSION (input );
3123
+ GC_TRY_UNPROTECT_RECURSION (input );
3124
3124
3125
3125
return output ;
3126
3126
}
@@ -4682,7 +4682,7 @@ MBSTRING_API int php_mb_check_encoding_recursive(HashTable *vars, const zend_str
4682
4682
php_error_docref (NULL , E_WARNING , "Cannot not handle circular references" );
4683
4683
return 0 ;
4684
4684
}
4685
- GC_PROTECT_RECURSION (vars );
4685
+ GC_TRY_PROTECT_RECURSION (vars );
4686
4686
ZEND_HASH_FOREACH_KEY_VAL (vars , idx , key , entry ) {
4687
4687
ZVAL_DEREF (entry );
4688
4688
if (key ) {
@@ -4716,7 +4716,7 @@ MBSTRING_API int php_mb_check_encoding_recursive(HashTable *vars, const zend_str
4716
4716
break ;
4717
4717
}
4718
4718
} ZEND_HASH_FOREACH_END ();
4719
- GC_UNPROTECT_RECURSION (vars );
4719
+ GC_TRY_UNPROTECT_RECURSION (vars );
4720
4720
mbfl_buffer_converter_delete (convd );
4721
4721
return valid ;
4722
4722
}
0 commit comments