diff options
Diffstat (limited to 'Zend/zend_object_handlers.c')
-rw-r--r-- | Zend/zend_object_handlers.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Zend/zend_object_handlers.c b/Zend/zend_object_handlers.c index 3196e50a5d..449c32408b 100644 --- a/Zend/zend_object_handlers.c +++ b/Zend/zend_object_handlers.c @@ -1025,7 +1025,7 @@ ZEND_API union _zend_function *zend_std_get_constructor(zval *object TSRMLS_DC) } else if (constructor->op_array.fn_flags & ZEND_ACC_PRIVATE) { /* Ensure that if we're calling a private function, we're allowed to do so. */ - if (Z_OBJ_HANDLER_P(object, get_class_entry)(object TSRMLS_CC) != EG(scope)) { + if (constructor->common.scope != EG(scope)) { if (EG(scope)) { zend_error(E_ERROR, "Call to private %s::%s() from context '%s'", constructor->common.scope->name, constructor->common.function_name, EG(scope)->name); } else { |