View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0002090 | Xdebug | Uncategorized | public | 2022-05-10 20:24 | 2022-06-06 15:28 |
| Reporter | NiNjA | Assigned To | |||
| Priority | normal | Severity | crash | Reproducibility | always |
| Status | closed | Resolution | fixed | ||
| Product Version | 3.1.4 | ||||
| Fixed in Version | 3.1.5 | ||||
| Summary | 0002090: Segfault in __callStatic() after FFI initialization | ||||
| Description | When I run the attached index.php script from command line or through nginx + php-fpm (and the debugger is attached to PhpStorm) the php process crashes. % PHP_IDE_CONFIG=serverName=test XDEBUG_SESSION=1 php index.php I expected to get this output without any segfault: I'm not 100% sure that this is an xdebug issue, however, it works just fine if I disable xdebug. It looks like that after FFI has been initialized, xdebug crashes when __callStatic() is about to be executed. I'm not that familiar with C and gdb, so I have not investigated this much further, but please let me know if you need any additional information. Note that this fails on both PHP 8.1.4 and 8.1.5, but I couldn't select 8.1.5 from the list. | ||||
| Steps To Reproduce |
| ||||
| Tags | ffi | ||||
| Operating System | Arch Linux | ||||
| PHP Version | 8.1.0-8.1.4 | ||||
|
|
Added attachments:
|
|
|
Hi, This does look like something dubious going on in ext/FFI, but there is a harmless workaround (an extra guard) to at least hide this problem within Xdebug, for which I have made a pull request: Once CI is happy, I'll merge it. Thanks for your detailed report. cheers, |