diff options
-rw-r--r-- | Zend/zend_execute_API.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index a1d30cb15b..a17d70aa45 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -113,6 +113,8 @@ static int is_not_internal_class(zend_class_entry **ce TSRMLS_DC) void init_executor(TSRMLS_D) { INIT_ZVAL(EG(uninitialized_zval)); +/* trick to make uninitialized_zval never be modified, passed by ref, etc. */ + EG(uninitialized_zval).refcount++; INIT_ZVAL(EG(error_zval)); EG(uninitialized_zval_ptr)=&EG(uninitialized_zval); EG(error_zval_ptr)=&EG(error_zval); |