php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #80468 Segfault on PHP 7.4.x and xDebug 3.0.0
Submitted: 2020-12-02 09:54 UTC Modified: 2020-12-02 10:30 UTC
From: michal dot jusiega at gmail dot com Assigned:
Status: Duplicate Package: *General Issues
PHP Version: 7.4.13 OS: Linux
Private report: No CVE-ID: None
 [2020-12-02 09:54 UTC] michal dot jusiega at gmail dot com
Description:
------------
Hello.

I found little bug - xDebug 3.0.0 with PHP 7.4 not working too good.

Expected result:
----------------
Should be ok.

Actual result:
--------------
gdb php
GNU gdb (Debian 8.2.1-2+b3) 8.2.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from php...(no debugging symbols found)...done.

(gdb) run /var/www/intranet/vendor/phpunit/phpunit/phpunit --configuration /var/www/intranet/phpunit.xml /var/www/intranet/tests/Controller/Webservices/REST/Druki
The program being debugged has been started already.
Starting program: /usr/local/bin/php /var/www/intranet/vendor/phpunit/phpunit/phpunit --configuration /var/www/intranet/phpunit.xml /var/www/intranet/tests/Controller/Webservices/REST/Druki
warning: Error disabling address space randomization: Operation not permitted
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
PHPUnit 9.4.4 by Sebastian Bergmann and contributors.

Testing /var/www/intranet/tests/Controller/Webservices/REST/Druki
..[New Thread 0x7f5c1b1ff700 (LWP 213)]
[Thread 0x7f5c1b1ff700 (LWP 213) exited]
.[New Thread 0x7f5c1b1ff700 (LWP 214)]
[Thread 0x7f5c1b1ff700 (LWP 214) exited]
.[New Thread 0x7f5c1b1ff700 (LWP 215)]
[Thread 0x7f5c1b1ff700 (LWP 215) exited]
.[New Thread 0x7f5c1b1ff700 (LWP 216)]
[Thread 0x7f5c1b1ff700 (LWP 216) exited]
.[New Thread 0x7f5c1b1ff700 (LWP 217)]
[Thread 0x7f5c1b1ff700 (LWP 217) exited]
.[New Thread 0x7f5c1b1ff700 (LWP 218)]
[Thread 0x7f5c1b1ff700 (LWP 218) exited]
...[New Thread 0x7f5c1b1ff700 (LWP 219)]
[Thread 0x7f5c1b1ff700 (LWP 219) exited]
.[New Thread 0x7f5c1b1ff700 (LWP 220)]
[Thread 0x7f5c1b1ff700 (LWP 220) exited]
.[New Thread 0x7f5c1b1ff700 (LWP 221)]
[Thread 0x7f5c1b1ff700 (LWP 221) exited]
.[New Thread 0x7f5c1b1ff700 (LWP 222)]
[Thread 0x7f5c1b1ff700 (LWP 222) exited]
.[New Thread 0x7f5c1b1ff700 (LWP 223)]
[Thread 0x7f5c1b1ff700 (LWP 223) exited]
.[New Thread 0x7f5c1b1ff700 (LWP 224)]
[Thread 0x7f5c1b1ff700 (LWP 224) exited]
.................
Thread 1 "php" received signal SIGSEGV, Segmentation fault.
0x00007f5c389f8181 in ?? () from /lib/x86_64-linux-gnu/libc.so.6

(gdb) bt
#0  0x00007f9015aac181 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#1  0x00005654432cc950 in ?? ()
#2  0x00005654432cd60b in ?? ()
#3  0x00005654432cd7ad in ap_php_vsnprintf ()
#4  0x00007f9012a5e44b in xdebug_sprintf (fmt=fmt@entry=0x7f9012a80bd5 ":%s:%d-%d}") at /tmp/pear/temp/xdebug/src/lib/str.c:215
#5  0x00007f9012a5c338 in xdebug_wrap_closure_location_around_function_name (opa=0x7f8ff7177278, fname=0x7f8ffac9e3e0 "newInstanceWithoutConstructor") at /tmp/pear/temp/xdebug/src/lib/lib.c:598
#6  0x00007f9012a56da1 in xdebug_build_fname (tmp=tmp@entry=0x565445bbf410, edata=edata@entry=0x7f9012816030) at /tmp/pear/temp/xdebug/src/base/base.c:264
#7  0x00007f9012a56ff9 in xdebug_add_stack_frame (zdata=<optimized out>, zdata@entry=0x7f9012816030, op_array=0x7f8ff7177278, type=type@entry=0) at /tmp/pear/temp/xdebug/src/base/base.c:637
#8  0x00007f9012a57eab in xdebug_execute_internal (current_execute_data=0x7f9012816030, return_value=0x7f9012815ed0) at /tmp/pear/temp/xdebug/src/base/base.c:888
#9  0x00005654433b08fc in execute_ex ()
#10 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815e50) at /tmp/pear/temp/xdebug/src/base/base.c:801
#11 0x00005654433b0097 in execute_ex ()
#12 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815cf0) at /tmp/pear/temp/xdebug/src/base/base.c:801
#13 0x00005654433b0097 in execute_ex ()
#14 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815c20) at /tmp/pear/temp/xdebug/src/base/base.c:801
#15 0x00005654433b0097 in execute_ex ()
#16 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815b40) at /tmp/pear/temp/xdebug/src/base/base.c:801
#17 0x00005654433b0097 in execute_ex ()
#18 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815a70) at /tmp/pear/temp/xdebug/src/base/base.c:801
#19 0x00005654433b0097 in execute_ex ()
#20 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f90128159c0) at /tmp/pear/temp/xdebug/src/base/base.c:801
#21 0x00005654433b0097 in execute_ex ()
#22 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f90128158d0) at /tmp/pear/temp/xdebug/src/base/base.c:801
#23 0x00005654433aefe0 in execute_ex ()
#24 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f90128157c0) at /tmp/pear/temp/xdebug/src/base/base.c:801
#25 0x00005654433b0097 in execute_ex ()
#26 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815730) at /tmp/pear/temp/xdebug/src/base/base.c:801
#27 0x00005654433b0097 in execute_ex ()
#28 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815620) at /tmp/pear/temp/xdebug/src/base/base.c:801
#29 0x00005654433b0097 in execute_ex ()
#30 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815530) at /tmp/pear/temp/xdebug/src/base/base.c:801
#31 0x00005654433b0097 in execute_ex ()
#32 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815450) at /tmp/pear/temp/xdebug/src/base/base.c:801
#33 0x00005654433b0097 in execute_ex ()
#34 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f90128153a0) at /tmp/pear/temp/xdebug/src/base/base.c:801
#35 0x00005654433b0097 in execute_ex ()
#36 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f90128152e0) at /tmp/pear/temp/xdebug/src/base/base.c:801
#37 0x00005654433b0097 in execute_ex ()
#38 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815250) at /tmp/pear/temp/xdebug/src/base/base.c:801
#39 0x00005654433b0097 in execute_ex ()
#40 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f90128151e0) at /tmp/pear/temp/xdebug/src/base/base.c:801
#41 0x00005654433b0097 in execute_ex ()
#42 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f90128150c0) at /tmp/pear/temp/xdebug/src/base/base.c:801
#43 0x00005654433aefe0 in execute_ex ()
#44 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012815000) at /tmp/pear/temp/xdebug/src/base/base.c:801
#45 0x00005654433b0097 in execute_ex ()
#46 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012814f60) at /tmp/pear/temp/xdebug/src/base/base.c:801
#47 0x00005654433b0097 in execute_ex ()
#48 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012814e90) at /tmp/pear/temp/xdebug/src/base/base.c:801
#49 0x00005654433aefe0 in execute_ex ()
#50 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012814c50) at /tmp/pear/temp/xdebug/src/base/base.c:801
#51 0x00005654433aefe0 in execute_ex ()
#52 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012814a00) at /tmp/pear/temp/xdebug/src/base/base.c:801
#53 0x00005654433aefe0 in execute_ex ()
#54 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f90128148b0) at /tmp/pear/temp/xdebug/src/base/base.c:801
#55 0x00005654433aefe0 in execute_ex ()
#56 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012814760) at /tmp/pear/temp/xdebug/src/base/base.c:801
#57 0x00005654433aefe0 in execute_ex ()
#58 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012814610) at /tmp/pear/temp/xdebug/src/base/base.c:801
#59 0x00005654433aefe0 in execute_ex ()
#60 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012814370) at /tmp/pear/temp/xdebug/src/base/base.c:801
#61 0x00005654433b0097 in execute_ex ()
#62 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012814290) at /tmp/pear/temp/xdebug/src/base/base.c:801
#63 0x00005654433b0097 in execute_ex ()
#64 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f90128141f0) at /tmp/pear/temp/xdebug/src/base/base.c:801
#65 0x00005654433aefe0 in execute_ex ()
#66 0x00007f9012a577d1 in xdebug_execute_ex (execute_data=0x7f9012814020) at /tmp/pear/temp/xdebug/src/base/base.c:801
#67 0x00005654433b1433 in zend_execute ()
#68 0x000056544332b5c3 in zend_execute_scripts ()
#69 0x00005654432cb240 in php_execute_script ()
#70 0x00005654433b3516 in ?? ()
#71 0x0000565443066a9b in ?? ()
#72 0x00007f901597409b in __libc_start_main () from /lib/x86_64-linux-gnu/libc.so.6
#73 0x00005654430671da in _start ()
(gdb)

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2020-12-02 10:07 UTC] michal dot jusiega at gmail dot com
-Summary: Segfault on PHP 7.4 and xDebug 3.0.0 +Summary: Segfault on PHP 7.4.x and xDebug 3.0.0
 [2020-12-02 10:07 UTC] michal dot jusiega at gmail dot com
Using xDebug 2.9.8 working as well.
 [2020-12-02 10:30 UTC] derick@php.net
-Status: Open +Status: Duplicate -Package: Xdebug +Package: *General Issues
 [2020-12-02 10:30 UTC] derick@php.net
Xdebug bugs go to the xdebug issue tracker: https://bugs.xdebug.org, where a better bug report for this already exists, and where you could have found that it is also already fixed and waiting to be released: https://bugs.xdebug.org/view.php?id=1896
 [2020-12-02 10:39 UTC] michal dot jusiega at gmail dot com
I didn't know there is a other issue tracker.
Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 26 19:01:29 2024 UTC