Skip to content

Commit 7a2212b

Browse files
fixed another mess up with the class access modifier
1 parent c253505 commit 7a2212b

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ INSTALL_LIB = ${INSTALL_PREFIX}/lib
5050
#
5151

5252
SONAME = 2.3
53-
VERSION = 2.3.3
53+
VERSION = 2.3.4
5454

5555

5656
#

zend/classimpl.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1366,9 +1366,6 @@ zend_class_entry *ClassImpl::initialize(ClassBase *base, const std::string &pref
13661366
// initialize the class entry
13671367
INIT_CLASS_ENTRY_EX(entry, _name.c_str(), _name.size(), entries());
13681368

1369-
// set access types flags for class
1370-
_entry->ce_flags |= (int)_type;
1371-
13721369
// we need a special constructor, but only for real classes, not for interfaces.
13731370
// (in fact: from php 7.4 onwards the create_object method is part of union
13741371
// together with the interface_gets_implemented method, which causes a crash
@@ -1424,7 +1421,7 @@ zend_class_entry *ClassImpl::initialize(ClassBase *base, const std::string &pref
14241421
// register the class
14251422
_entry = zend_register_internal_class(&entry);
14261423
}
1427-
1424+
14281425
// register the interfaces
14291426
for (auto &interface : _interfaces)
14301427
{
@@ -1439,6 +1436,9 @@ zend_class_entry *ClassImpl::initialize(ClassBase *base, const std::string &pref
14391436
if (_base->traversable()) zend_class_implements(_entry, 1, zend_ce_traversable);
14401437
if (_base->serializable()) zend_class_implements(_entry, 1, zend_ce_serializable);
14411438

1439+
// instal the right modifier (to make the class an interface, abstract class, etc)
1440+
_entry->ce_flags |= uint64_t(_type);
1441+
14421442
// this pointer has to be copied to temporary pointer, as &this causes compiler error
14431443
ClassImpl *impl = this;
14441444

0 commit comments

Comments
 (0)