From 0fdf668dce21a2bdab5f0d76b3b8dc3879e661fd Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Thu, 15 Apr 2021 15:31:45 +0300 Subject: [PATCH] Keep fci->object unchanged --- Zend/zend_execute_API.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 7d5adad3042..7117e769cc7 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -725,12 +725,10 @@ zend_result zend_call_function(zend_fcall_info *fci, zend_fcall_info_cache *fci_ func = fci_cache->function_handler; if ((func->common.fn_flags & ZEND_ACC_STATIC) || !fci_cache->object) { - fci->object = NULL; object_or_called_scope = fci_cache->called_scope; call_info = ZEND_CALL_TOP_FUNCTION | ZEND_CALL_DYNAMIC; } else { - fci->object = fci_cache->object; - object_or_called_scope = fci->object; + object_or_called_scope = fci_cache->object; call_info = ZEND_CALL_TOP_FUNCTION | ZEND_CALL_DYNAMIC | ZEND_CALL_HAS_THIS; }