Skip to content

Commit 0aaa062

Browse files
committed
Change into zend_collect_module_entries
1 parent 424e426 commit 0aaa062

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

Zend/zend.c

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1091,16 +1091,14 @@ zend_result zend_post_startup(void) /* {{{ */
10911091
}
10921092
/* }}} */
10931093

1094-
/* Returns a NULL-terminated array of module entries that were dynamically loaded. */
1095-
static zend_module_entry **zend_collect_dl_loaded_module_entries(void)
1094+
/* Returns a NULL-terminated array of module entries. */
1095+
static zend_module_entry **zend_collect_module_entries(void)
10961096
{
10971097
zend_module_entry **modules = malloc(sizeof(zend_module_entry *) * (zend_hash_num_elements(&module_registry) + 1));
10981098
zend_module_entry *module;
10991099
unsigned int index = 0;
11001100
ZEND_HASH_MAP_REVERSE_FOREACH_PTR(&module_registry, module) {
1101-
if (module->handle) {
1102-
modules[index++] = module;
1103-
}
1101+
modules[index++] = module;
11041102
} ZEND_HASH_FOREACH_END();
11051103
modules[index] = NULL;
11061104
return modules;
@@ -1116,7 +1114,7 @@ static void zend_unload_modules(zend_module_entry **modules)
11161114

11171115
void zend_shutdown(void) /* {{{ */
11181116
{
1119-
zend_module_entry **modules = zend_collect_dl_loaded_module_entries();
1117+
zend_module_entry **modules = zend_collect_module_entries();
11201118

11211119
zend_vm_dtor();
11221120

0 commit comments

Comments
 (0)