summaryrefslogtreecommitdiff
path: root/Zend/zend_object_handlers.c
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@php.net>2008-02-21 13:55:45 +0000
committerDmitry Stogov <dmitry@php.net>2008-02-21 13:55:45 +0000
commit3e7e9d4af6c275618896dc971ec561d9f54d023e (patch)
tree436ebafd9909feadb732b0d89ada21d008dbf7ed /Zend/zend_object_handlers.c
parent9609e195e9f512b642a2aa7e8a015076f3c56086 (diff)
downloadphp-git-3e7e9d4af6c275618896dc971ec561d9f54d023e.tar.gz
Fixed bug #44141 (private parent constructor callable through static function)
Diffstat (limited to 'Zend/zend_object_handlers.c')
-rw-r--r--Zend/zend_object_handlers.c2
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 {