]> granicus.if.org Git - php/commitdiff
Fix uninitialized value with extension traits
authorJohn Boehr <jbboehr@gmail.com>
Sun, 3 May 2015 21:29:19 +0000 (14:29 -0700)
committerXinchen Hui <laruence@php.net>
Mon, 4 May 2015 02:33:26 +0000 (10:33 +0800)
NEWS
Zend/zend_compile.c

diff --git a/NEWS b/NEWS
index cb2d07d92a1680afbde39aef93a19d4c8b1fedd4..373098ded3ea83ab91a807744c205b5ce8e9202a 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -5,6 +5,8 @@ PHP                                                                        NEWS
 14 Jun 2015, PHP 5.6.9
 
 - Core:
+  . Fixed bug #69566 (Conditional jump or move depends on uninitialised value
+    in extension trait). (jbboehr at gmail dot com)
   . Fixed bug #69467 (Wrong checked for the interface by using Trait). 
     (Laruence)
   . Fixed bug #69420 (Invalid read in zend_std_get_method). (Laruence)
index 0f343e7f14d507ba4c434b0065185bd3cede701c..d2f9fbc8d74836fe8a8459791a5fa4cf2880cdd4 100644 (file)
@@ -4101,7 +4101,7 @@ static int zend_fixup_trait_method(zend_function *fn, zend_class_entry *ce TSRML
                if (fn->common.fn_flags & ZEND_ACC_ABSTRACT) {
                        ce->ce_flags |= ZEND_ACC_IMPLICIT_ABSTRACT_CLASS;
                }
-               if (fn->op_array.static_variables) {
+               if (fn->type == ZEND_USER_FUNCTION && fn->op_array.static_variables) {
                        ce->ce_flags |= ZEND_HAS_STATIC_IN_METHODS;
                }
        }