View Issue Details

IDProjectCategoryView StatusLast Update
0001736XdebugStep Debuggingpublic2020-01-22 16:02
ReporterSammyKAssigned Toderick 
Status closedResolutionfixed 
Product Version2.9.1 
Target Version2.9.2Fixed in Version2.9.2 
Summary0001736: Segmentation fault when other extensions run PHP in RINIT
DescriptionStarting in Xdebug 2.9.1, when `xdebug.remote_enable=1`, Xdebug can cause a segmentation fault when another extension makes a call to `zend_compile_file()` in RINIT.

In the case of the Datadog PHP tracer extension, when ddtrace's RINIT is run before Xdebug's RINIT, XG_DBG(breakable_lines_map) is not yet allocated so the segmentation fault occurs when trying to execute a PHP file set via the ddtrace.request_init_hook INI setting:

A possible fix PR can be found here:
Steps To ReproduceSet `xdebug.remote_enable=1` and then call `zend_compile_file()` from a neighboring extension's RINIT before Xdebug's RINIT is run.
TagsNo tags attached.
Operating System
PHP Version7.4.0-7.4.4



2020-01-22 16:01

administrator   ~0005222

Thanks for the test, and fix! I've merged this now.

Issue History

Date Modified Username Field Change
2020-01-21 18:26 SammyK New Issue
2020-01-22 16:00 derick Target Version => 2.9.2
2020-01-22 16:01 derick Assigned To => derick
2020-01-22 16:01 derick Status new => closed
2020-01-22 16:01 derick Resolution open => fixed
2020-01-22 16:01 derick Fixed in Version => 2.9dev
2020-01-22 16:01 derick Note Added: 0005222
2020-01-22 16:02 derick Fixed in Version 2.9dev => 2.9.2
2020-03-12 16:33 derick Category Remote Debugging => Step Debugging