Bug #78592 [Fbk->Opn]: filter related extension cause Segmentation fault
| From: | requinix@php.net | Date: | Thu, 26 Sep 2019 01:57:01 +0000 |
| Subject: | Bug #78592 [Fbk->Opn]: filter related extension cause Segmentation fault | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-222915@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=78592&edit=1
ID: 78592
Updated by: requinix@php.net
Reported by: john dot royer at gmail dot com
Summary: filter related extension cause Segmentation fault
-Status: Feedback
+Status: Open
Type: Bug
-Package: Filter related
+Package: JSON related
Operating System: Linux (Ubuntu 18.04)
PHP Version: 7.3.9
Block user comment: N
Private report: N
New Comment:
> Is it means PHP crashed while using JSON extension ?
More or less. The issue could be with json_decode(), or it could be with the engine internals that
the function was using.
What if you phpbrew install with filter and without json? Or with json and without filter?
Previous Comments:
------------------------------------------------------------------------
[2019-09-26 01:48:10] john dot royer at gmail dot com
I got a core dump, as below:
$ gdb
which php core-php.21646
GNU gdb (Ubuntu 8.1-0ubuntu3.1) 8.1.0.20180409-git
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 /usr/bin/php...(no debugging symbols found)...done.
warning: core file may not match specified executable file.
[New LWP 21646]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `php vendor/bin/phpunit'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 0x000055e98d4fa1f2 in _emalloc_56 ()
(gdb) bt
#0 0x000055e98d4fa1f2 in _emalloc_56 ()
#1 0x000055e98d52d149 in _zend_new_array_0 ()
#2 0x00007f1840827d99 in ?? () from /usr/lib/php/20180731/json.so
#3 0x00007f1840828589 in ?? () from /usr/lib/php/20180731/json.so
#4 0x00007f18408253f6 in php_json_decode_ex () from /usr/lib/php/20180731/json.so
#5 0x00007f18408255c9 in ?? () from /usr/lib/php/20180731/json.so
#6 0x000055e98d5b011b in execute_ex ()
#7 0x000055e98d5b03f3 in zend_execute ()
#8 0x000055e98d521272 in zend_execute_scripts ()
#9 0x000055e98d4c11f0 in php_execute_script ()
#10 0x000055e98d5b28cc in ?? ()
#11 0x000055e98d3786fb in ?? ()
#12 0x00007f184af64b97 in __libc_start_main (main=0x55e98d3782e0, argc=2, argv=0x7ffd793af448,
init=<optimized out>, fini=<optimized out>,
rtld_fini=<optimized out>, stack_end=0x7ffd793af438) at ../csu/libc-start.c:310
#13 0x000055e98d37889a in _start ()
//==================================
I don't know about gbd. Is it means PHP crashed while using JSON extension ?
------------------------------------------------------------------------
[2019-09-25 09:42:31] requinix@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php
for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php
for Win32
Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.
------------------------------------------------------------------------
[2019-09-25 07:22:04] john dot royer at gmail dot com
Description:
------------
$ phpunit
... Run by vendor/bin/phpunit ...
PHPUnit 7.5.15 by Sebastian Bergmann and contributors.
............................................................Segmentation fault (core dumped)
//-------------------------------
Sorry, issue cause only run after a lot of tests. If I just run patial test, like phpunit
test/src/ApplicationTest.php, there is no error occur.
My PHP environment is as the gist shown: https://gist.github.com/johnroyer/1c05332c94db0374ffc0d823fee0818b.
Hope this helps.
Test script:
---------------
I use phpbrew to rebuild PHP 7.3.9 and add extension step by step. Issue occurs after a compile
filter library :
phpbrew install 7.3.9 +cli +json +pdo +xml +curl +mysql +hash +ctype +openssl +filter
Expected result:
----------------
PHPUnit should run all the test and should not have any PHP language related issue.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=78592&edit=1