]> granicus.if.org Git - php/commitdiff
Fixed bug #33277 (private method accessed by child class)
authorDmitry Stogov <dmitry@php.net>
Fri, 17 Jun 2005 10:50:45 +0000 (10:50 +0000)
committerDmitry Stogov <dmitry@php.net>
Fri, 17 Jun 2005 10:50:45 +0000 (10:50 +0000)
NEWS
Zend/zend_object_handlers.c

diff --git a/NEWS b/NEWS
index 5243f9f2f673485d65c9a00db8a5bcbc95fca7bf..2b867a02d601ff52117758cb785cab9fa51472ca 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -15,6 +15,7 @@ PHP                                                                        NEWS
 - Fixed bug #33318 (throw 1; results in Invalid opcode 108/1/8). (Dmitry)
 - Fixed bug #33312 (ReflectionParameter methods do not work correctly).
   (Dmitry)
+- Fixed bug #33277 (private method accessed by child class). (Dmitry)
 - Fixed bug #33212 ([GCC 4]: 'zend_error_noreturn' aliased to external symbol
   'zend_error'). (Dmitry)
 - Fixed bug #31256 (PHP_EVAL_LIBLINE configure macro does not handle -pthread).
index dd80e0d6ec4974a237f970f7b7e08b1f63c7d71a..3164a177d26580d40ab033f6bb4f9ce1e2a34a64 100644 (file)
@@ -676,7 +676,8 @@ static union _zend_function *zend_std_get_method(zval **object_ptr, char *method
                        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;
                        }
                }