From 276f733effc4989b32b71d1ba0033e02b727fe13 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Fri, 17 Jun 2005 10:51:10 +0000 Subject: [PATCH] Fixed bug #33277 (private method accessed by child class) --- NEWS | 1 + Zend/zend_object_handlers.c | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index f3bacf9f6c..3748bbb3ba 100644 --- a/NEWS +++ b/NEWS @@ -15,6 +15,7 @@ PHP NEWS - Fixed memory corruption in stristr(). (Derick) - Fixed segfaults when CURL callback functions throw exception. (Tony) - Fixed bug #33340 (CLI Crash when calling php:function from XSLT). (Rob) +- Fixed bug #33277 (private method accessed by child class). (Dmitry) - Fixed bug #33268 (iconv_strlen() works only with a parameter of < 3 in length). (Ilia) - Fixed bug #33243 (ze1_compatibility_mode does not work as expected). (Dmitry) diff --git a/Zend/zend_object_handlers.c b/Zend/zend_object_handlers.c index 5404e99c76..9d3f09bca6 100644 --- a/Zend/zend_object_handlers.c +++ b/Zend/zend_object_handlers.c @@ -746,7 +746,8 @@ static union _zend_function *zend_std_get_method(zval *object, char *method_name zend_function *priv_fbc; if (zend_hash_find(&EG(scope)->function_table, lc_method_name, method_len+1, (void **) &priv_fbc)==SUCCESS - && priv_fbc->common.fn_flags & ZEND_ACC_PRIVATE) { + && priv_fbc->common.fn_flags & ZEND_ACC_PRIVATE + && priv_fbc->common.scope == EG(scope)) { fbc = priv_fbc; } } -- 2.50.1