@@ -3067,7 +3067,8 @@ static int zend_is_callable_check_func(int check_flags, zval *callable, zend_fca
3067
3067
(!fcc -> function_handler -> common .scope ||
3068
3068
!instanceof_function (ce_org , fcc -> function_handler -> common .scope ))) {
3069
3069
if (fcc -> function_handler -> common .fn_flags & ZEND_ACC_CALL_VIA_TRAMPOLINE ) {
3070
- if (fcc -> function_handler -> type != ZEND_OVERLOADED_FUNCTION ) {
3070
+ if (fcc -> function_handler -> type != ZEND_OVERLOADED_FUNCTION &&
3071
+ fcc -> function_handler -> common .function_name ) {
3071
3072
zend_string_release (fcc -> function_handler -> common .function_name );
3072
3073
}
3073
3074
zend_free_trampoline (fcc -> function_handler );
@@ -3237,7 +3238,8 @@ ZEND_API zend_bool zend_is_callable_ex(zval *callable, zend_object *object, uint
3237
3238
((fcc -> function_handler -> common .fn_flags & ZEND_ACC_CALL_VIA_TRAMPOLINE ) ||
3238
3239
fcc -> function_handler -> type == ZEND_OVERLOADED_FUNCTION_TEMPORARY ||
3239
3240
fcc -> function_handler -> type == ZEND_OVERLOADED_FUNCTION )) {
3240
- if (fcc -> function_handler -> type != ZEND_OVERLOADED_FUNCTION ) {
3241
+ if (fcc -> function_handler -> type != ZEND_OVERLOADED_FUNCTION &&
3242
+ fcc -> function_handler -> common .function_name ) {
3241
3243
zend_string_release (fcc -> function_handler -> common .function_name );
3242
3244
}
3243
3245
zend_free_trampoline (fcc -> function_handler );
@@ -3324,7 +3326,8 @@ ZEND_API zend_bool zend_is_callable_ex(zval *callable, zend_object *object, uint
3324
3326
((fcc -> function_handler -> common .fn_flags & ZEND_ACC_CALL_VIA_TRAMPOLINE ) ||
3325
3327
fcc -> function_handler -> type == ZEND_OVERLOADED_FUNCTION_TEMPORARY ||
3326
3328
fcc -> function_handler -> type == ZEND_OVERLOADED_FUNCTION )) {
3327
- if (fcc -> function_handler -> type != ZEND_OVERLOADED_FUNCTION ) {
3329
+ if (fcc -> function_handler -> type != ZEND_OVERLOADED_FUNCTION &&
3330
+ fcc -> function_handler -> common .function_name ) {
3328
3331
zend_string_release (fcc -> function_handler -> common .function_name );
3329
3332
}
3330
3333
zend_free_trampoline (fcc -> function_handler );
0 commit comments