Skip to content

Commit ec3f300

Browse files
committed
Fix observer leak
Make sure to startup observer infrastructure before we register the first observer...
1 parent e413b4c commit ec3f300

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

main/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2044,6 +2044,7 @@ int php_module_startup(sapi_module_struct *sf, zend_module_entry *additional_mod
20442044
zend_startup(&zuf);
20452045
zend_update_current_locale();
20462046

2047+
zend_observer_startup();
20472048
#if ZEND_DEBUG
20482049
zend_observer_error_register(report_zend_debug_error_notify_cb);
20492050
#endif
@@ -2192,7 +2193,6 @@ int php_module_startup(sapi_module_struct *sf, zend_module_entry *additional_mod
21922193
php_startup_auto_globals();
21932194
zend_set_utility_values(&zuv);
21942195
php_startup_sapi_content_types();
2195-
zend_observer_startup();
21962196

21972197
/* startup extensions statically compiled in */
21982198
if (php_register_internal_extensions_func() == FAILURE) {

0 commit comments

Comments
 (0)