diff options
author | krakjoe <joe.watkins@live.co.uk> | 2014-11-25 08:37:02 +0000 |
---|---|---|
committer | krakjoe <joe.watkins@live.co.uk> | 2014-11-25 08:37:02 +0000 |
commit | e07feeaf8b91f16a89e9903b461042a0f6a63ac0 (patch) | |
tree | 4a94cd382fcffefff920f7733562e1860a66cc44 /Zend/zend_builtin_functions.c | |
parent | 9b6836ebd36eccc9e81ca51e2efe172e1d334f0b (diff) | |
parent | d4f42289ddde002cb4d3ed9d1a4f2219f68df48e (diff) | |
download | php-git-e07feeaf8b91f16a89e9903b461042a0f6a63ac0.tar.gz |
Merge branch 'master' of https://github.com/php/php-src
Diffstat (limited to 'Zend/zend_builtin_functions.c')
-rw-r--r-- | Zend/zend_builtin_functions.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index ddec6a7ddb..ecb8f4e0d1 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -954,12 +954,10 @@ static void add_class_vars(zend_class_entry *ce, int statics, zval *return_value continue; } prop = NULL; - if (prop_info->offset >= 0) { - if (statics && (prop_info->flags & ZEND_ACC_STATIC) != 0) { - prop = &ce->default_static_members_table[prop_info->offset]; - } else if (!statics && (prop_info->flags & ZEND_ACC_STATIC) == 0) { - prop = &ce->default_properties_table[prop_info->offset]; - } + if (statics && (prop_info->flags & ZEND_ACC_STATIC) != 0) { + prop = &ce->default_static_members_table[prop_info->offset]; + } else if (!statics && (prop_info->flags & ZEND_ACC_STATIC) == 0) { + prop = &ce->default_properties_table[OBJ_PROP_TO_NUM(prop_info->offset)]; } if (!prop || Z_TYPE_P(prop) == IS_UNDEF) { continue; |