Skip to content

Instantly share code, notes, and snippets.

@derickr
Created October 6, 2021 14:13
Show Gist options
  • Save derickr/73d42bf0a3bde47fcd88cf029e9e4730 to your computer and use it in GitHub Desktop.
Save derickr/73d42bf0a3bde47fcd88cf029e9e4730 to your computer and use it in GitHub Desktop.
reset-globals
diff --git xdebug.c xdebug.c
index c1228857..3a4bcc23 100644
--- xdebug.c
+++ xdebug.c
@@ -406,6 +406,8 @@ static void xdebug_init_base_globals(xdebug_base_globals_t *xg)
static void php_xdebug_init_globals(zend_xdebug_globals *xg)
{
+ memset(&xg->globals, 0, sizeof(xg->globals));
+
xdebug_init_library_globals(&xg->globals.library);
xdebug_init_base_globals(&xg->globals.base);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment