Skip to content

Commit 3c97761

Browse files
dreamsxinnikic
authored andcommitted
Fix dom class can't be inherited by the internal class
1 parent 97e16eb commit 3c97761

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/dom/php_dom.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1075,7 +1075,7 @@ static dom_object* dom_objects_set_class(zend_class_entry *class_type, zend_bool
10751075
dom_object *intern = ecalloc(1, sizeof(dom_object) + zend_object_properties_size(class_type));
10761076

10771077
zend_class_entry *base_class = class_type;
1078-
while (base_class->type != ZEND_INTERNAL_CLASS && base_class->parent != NULL) {
1078+
while ((base_class->type != ZEND_INTERNAL_CLASS || base_class->info.internal.module->module_number != dom_module_entry.module_number) && base_class->parent != NULL) {
10791079
base_class = base_class->parent;
10801080
}
10811081

0 commit comments

Comments
 (0)