View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0001651 | Xdebug | Profiling | public | 2019-03-26 19:25 | 2019-06-28 11:50 |
Reporter | stantheman | Assigned To | derick | ||
Priority | normal | Severity | crash | Reproducibility | have not tried |
Status | resolved | Resolution | duplicate | ||
Product Version | 2.7.0 | ||||
Summary | 0001651: segfault in xdebug_var_export with collect_params set to 3 or 4 | ||||
Description | In xdebug_var.c, the xdebug_var_export function calls xdebug_objdebug_pp, which can return NULL. If it's NULL, the following call to xdebug_zend_hash_is_recursive causes a segfault: https://github.com/xdebug/xdebug/blob/xdebug_2_7/xdebug_var.c#L1049 This happens in v2.6.1 as well as a fresh build from master. | ||||
Steps To Reproduce | I don't have a minimal repro. It happens when tracing a CLI script and selling xdebug.collect_params to a value of '3' or '4'. I collect the values on the CLI with: php -d 'zend_extension=/usr/lib64/php/modules7/xdebug.so' -d 'xdebug.trace_format=1' -d 'xdebug.auto_trace=1' -d 'xdebug.trace_output_dir=/tmp/xdebug' -d 'xdebug.profiler_enable=1' -d 'xdebug.profiler_enable=On' -d 'xdebug.collect_params=4' bigtable.php | ||||
Additional Information | gdb from the segfault: (gdb) zbacktrace (gdb) bt I have a patch to submit on github but need this reference number to make the PR | ||||
Tags | No tags attached. | ||||
Operating System | |||||
PHP Version | 7.1.15-7.1.19 | ||||
|
Pull request is here: https://github.com/xdebug/xdebug/pull/461 |
|
Hi, thanks for the ticket and pull request. I would need to have a minimal test case before I can merge that though. Can you produce one? I wouldn't want to merge this PR as it might just fix a symptom, and not the real cause. And I would also not want to reintroduce the bug in the future, so a test case is really needed. cheers, |
|
Would you please have a test case? |
|
I am pretty sure this has the same root cause as the issue described in 0001665. I'm therefore merging them, and marking this one as duplicate. |
Date Modified | Username | Field | Change |
---|---|---|---|
2019-03-26 19:25 | stantheman | New Issue | |
2019-03-26 19:34 | stantheman | Note Added: 0004978 | |
2019-04-03 15:53 | derick | Assigned To | => derick |
2019-04-03 15:53 | derick | Status | new => feedback |
2019-04-03 15:53 | derick | Note Added: 0004982 | |
2019-04-26 10:25 | derick | Note Added: 0005009 | |
2019-06-28 11:50 | derick | Status | feedback => resolved |
2019-06-28 11:50 | derick | Resolution | open => duplicate |
2019-06-28 11:50 | derick | Note Added: 0005048 | |
2019-06-28 11:50 | derick | Relationship added | duplicate of 0001665 |