php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #68043 Error when stopping PHP built-in web server
Submitted: 2014-09-18 11:30 UTC Modified: 2020-12-20 04:22 UTC
Votes:6
Avg. Score:4.3 ± 0.9
Reproduced:5 of 6 (83.3%)
Same Version:2 (40.0%)
Same OS:2 (40.0%)
From: abi at hafs dot in Assigned: cmb (profile)
Status: No Feedback Package: Built-in web server
PHP Version: 5.5.16 OS: Arch Linux 64bit
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2014-09-18 11:30 UTC] abi at hafs dot in
Description:
------------
PHP Version => 5.5.16

System => Linux haf 3.16.2-1-uksm-ck #1 SMP PREEMPT Thu Sep 11 14:02:10 WIB 2014 x86_64
Build Date => Aug 21 2014 18:34:04

Configure Command =>  './configure'  '--srcdir=../php-5.5.16' '--config-cache' '--prefix=/usr' '--sbindir=/usr/bin' '--sysconfdir=/etc/php' '--localstatedir=/var' '--with-layout=GNU' '--with-config-file-path=/etc/php' '--with-config-file-scan-dir=/etc/php/conf.d' '--disable-rpath' '--mandir=/usr/share/man' '--without-pear' '--disable-cgi' '--with-readline' '--enable-pcntl' '--enable-bcmath=shared' '--enable-calendar=shared' '--enable-dba=shared' '--enable-exif=shared' '--enable-ftp=shared' '--enable-gd-native-ttf' '--enable-intl=shared' '--enable-mbstring' '--enable-opcache' '--enable-phar=shared' '--enable-posix=shared' '--enable-shmop=shared' '--enable-soap=shared' '--enable-sockets=shared' '--enable-sysvmsg=shared' '--enable-sysvsem=shared' '--enable-sysvshm=shared' '--enable-zip=shared' '--with-bz2=shared' '--with-curl=shared' '--with-db4=/usr' '--with-enchant=shared,/usr' '--with-fpm-systemd' '--with-freetype-dir=/usr' '--with-gd=shared' '--with-gdbm' '--with-gettext=shared' '--with-gmp=shared' '--with-iconv=shared' '--with-icu-dir=/usr' '--with-imap-ssl' '--with-imap=shared' '--with-jpeg-dir=/usr' '--with-vpx-dir=/usr' '--with-ldap=shared' '--with-ldap-sasl' '--with-mcrypt=shared' '--with-mhash' '--with-mssql=shared' '--with-mysql-sock=/run/mysqld/mysqld.sock' '--with-mysql=shared,mysqlnd' '--with-mysqli=shared,mysqlnd' '--with-openssl=shared' '--with-pcre-regex=/usr' '--with-pdo-mysql=shared,mysqlnd' '--with-pdo-odbc=shared,unixODBC,/usr' '--with-pdo-pgsql=shared' '--with-pdo-sqlite=shared,/usr' '--with-pgsql=shared' '--with-png-dir=/usr' '--with-pspell=shared' '--with-snmp=shared' '--with-sqlite3=shared,/usr' '--with-tidy=shared' '--with-unixODBC=shared,/usr' '--with-xmlrpc=shared' '--with-xsl=shared' '--with-zlib'
Server API => Command Line Interface
Virtual Directory Support => disabled
Configuration File (php.ini) Path => /etc/php
Loaded Configuration File => /etc/php/php.ini


Test script:
---------------
$ php -S localhost:8080

^C

Expected result:
----------------
Php built-in web server stops

Actual result:
--------------
^C*** Error in `php': free(): invalid pointer: 0x00007fd9f9e963c0 ***
======= Backtrace: =========
/usr/lib/libc.so.6(+0x73f8e)[0x7fda07a24f8e]
/usr/lib/libc.so.6(+0x7988e)[0x7fda07a2a88e]
/usr/lib/libc.so.6(+0x7a04b)[0x7fda07a2b04b]
php(php_module_shutdown+0x2e)[0x5e62be]
php[0x424cee]
/usr/lib/libc.so.6(__libc_start_main+0xf0)[0x7fda079d1000]
php[0x424eb1]
======= Memory map: ========
00400000-00b7f000 r-xp 00000000 08:01 393289                             /usr/bin/php
00d7f000-00e21000 r--p 0077f000 08:01 393289                             /usr/bin/php
00e21000-00e2c000 rw-p 00821000 08:01 393289                             /usr/bin/php
00e2c000-00e49000 rw-p 00000000 00:00 0 
01354000-016d2000 rw-p 00000000 00:00 0                                  [heap]
7fd9f9bd4000-7fd9f9bdf000 r-xp 00000000 08:01 263849                     /usr/lib/libnss_files-2.19.so
7fd9f9bdf000-7fd9f9dde000 ---p 0000b000 08:01 263849                     /usr/lib/libnss_files-2.19.so
7fd9f9dde000-7fd9f9ddf000 r--p 0000a000 08:01 263849                     /usr/lib/libnss_files-2.19.so
7fd9f9ddf000-7fd9f9de0000 rw-p 0000b000 08:01 263849                     /usr/lib/libnss_files-2.19.so
7fd9f9de0000-7fd9fdde0000 rw-s 00000000 00:04 38276                      /dev/zero (deleted)
7fda0150a000-7fda01511000 r-xp 00000000 08:01 263850                     /usr/lib/librt-2.19.so
7fda01511000-7fda01710000 ---p 00007000 08:01 263850                     /usr/lib/librt-2.19.so
7fda01710000-7fda01711000 r--p 00006000 08:01 263850                     /usr/lib/librt-2.19.so
7fda01711000-7fda01712000 rw-p 00007000 08:01 263850                     /usr/lib/librt-2.19.so
7fda02c48000-7fda02d38000 r-xp 00000000 08:01 263774                     /usr/lib/libstdc++.so.6.0.20
7fda02d38000-7fda02f38000 ---p 000f0000 08:01 263774                     /usr/lib/libstdc++.so.6.0.20
7fda02f38000-7fda02f40000 r--p 000f0000 08:01 263774                     /usr/lib/libstdc++.so.6.0.20
7fda02f40000-7fda02f42000 rw-p 000f8000 08:01 263774                     /usr/lib/libstdc++.so.6.0.20
7fda02f42000-7fda02f57000 rw-p 00000000 00:00 0 
7fda02f57000-7fda02f6d000 r-xp 00000000 08:01 263610                     /usr/lib/libgcc_s.so.1
7fda02f6d000-7fda0316c000 ---p 00016000 08:01 263610                     /usr/lib/libgcc_s.so.1
7fda0316c000-7fda0316d000 rw-p 00015000 08:01 263610                     /usr/lib/libgcc_s.so.1
7fda07104000-7fda0730b000 r--p 00000000 08:01 275973                     /usr/lib/locale/locale-archive
7fda0730b000-7fda0732c000 r-xp 00000000 08:01 266866                     /usr/lib/liblzma.so.5.0.5
7fda0732c000-7fda0752c000 ---p 00021000 08:01 266866                     /usr/lib/liblzma.so.5.0.5
7fda0752c000-7fda0752d000 r--p 00021000 08:01 266866                     /usr/lib/liblzma.so.5.0.5
7fda0752d000-7fda0752e000 rw-p 00022000 08:01 266866                     /usr/lib/liblzma.so.5.0.5
7fda0752e000-7fda07546000 r-xp 00000000 08:01 266768                     /usr/lib/libpthread-2.19.so
7fda07546000-7fda07746000 ---p 00018000 08:01 266768                     /usr/lib/libpthread-2.19.so
7fda07746000-7fda07747000 r--p 00018000 08:01 266768                     /usr/lib/libpthread-2.19.so
7fda07747000-7fda07748000 rw-p 00019000 08:01 266768                     /usr/lib/libpthread-2.19.so
7fda07748000-7fda0774c000 rw-p 00000000 00:00 0 
7fda0774c000-7fda077ac000 r-xp 00000000 08:01 266794                     /usr/lib/libncursesw.so.5.9
7fda077ac000-7fda079ab000 ---p 00060000 08:01 266794                     /usr/lib/libncursesw.so.5.9
7fda079ab000-7fda079af000 r--p 0005f000 08:01 266794                     /usr/lib/libncursesw.so.5.9
7fda079af000-7fda079b1000 rw-p 00063000 08:01 266794                     /usr/lib/libncursesw.so.5.9
7fda079b1000-7fda07b55000 r-xp 00000000 08:01 263884                     /usr/lib/libc-2.19.so
7fda07b55000-7fda07d55000 ---p 001a4000 08:01 263884                     /usr/lib/libc-2.19.so
7fda07d55000-7fda07d59000 r--p 001a4000 08:01 263884                     /usr/lib/libc-2.19.so
7fda07d59000-7fda07d5b000 rw-p 001a8000 08:01 263884                     /usr/lib/libc-2.19.so
7fda07d5b000-7fda07d5f000 rw-p 00000000 00:00 0 
7fda07d5f000-7fda07f45000 r-xp 00000000 08:01 275986                     /usr/lib/libcrypto.so.1.0.0
7fda07f45000-7fda08145000 ---p 001e6000 08:01 275986                     /usr/lib/libcrypto.so.1.0.0
7fda08145000-7fda08161000 r--p 001e6000 08:01 275986                     /usr/lib/libcrypto.so.1.0.0
7fda08161000-7fda0816d000 rw-p 00202000 08:01 275986                     /usr/lib/libcrypto.so.1.0.0
7fda0816d000-7fda08171000 rw-p 00000000 00:00 0 
7fda08171000-7fda082ce000 r-xp 00000000 08:01 275193                     /usr/lib/libxml2.so.2.9.1
7fda082ce000-7fda084cd000 ---p 0015d000 08:01 275193                     /usr/lib/libxml2.so.2.9.1
7fda084cd000-7fda084d5000 r--p 0015c000 08:01 275193                     /usr/lib/libxml2.so.2.9.1
7fda084d5000-7fda084d7000 rw-p 00164000 08:01 275193                     /usr/lib/libxml2.so.2.9.1
7fda084d7000-7fda084d9000 rw-p 00000000 00:00 0 
7fda084d9000-7fda084dc000 r-xp 00000000 08:01 262777                     /usr/lib/libdl-2.19.so
7fda084dc000-7fda086db000 ---p 00003000 08:01 262777                     /usr/lib/libdl-2.19.so
7fda086db000-7fda086dc000 r--p 00002000 08:01 262777                     /usr/lib/libdl-2.19.so
7fda086dc000-7fda086dd000 rw-p 00003000 08:01 262777                     /usr/lib/libdl-2.19.so
7fda086dd000-7fda087e0000 r-xp 00000000 08:01 262517                     /usr/lib/libm-2.19.so
7fda087e0000-7fda089df000 ---p 00103000 08:01 262517                     /usr/lib/libm-2.19.so
7fda089df000-7fda089e0000 r--p 00102000 08:01 262517                     /usr/lib/libm-2.19.so
7fda089e0000-7fda089e1000 rw-p 00103000 08:01 262517                     /usr/lib/libm-2.19.so
7fda089e1000-7fda08a4a000 r-xp 00000000 08:01 274629                     /usr/lib/libpcre.so.1.2.3
7fda08a4a000-7fda08c49000 ---p 00069000 08:01 274629                     /usr/lib/libpcre.so.1.2.3
7fda08c49000-7fda08c4a000 r--p 00068000 08:01 274629                     /usr/lib/libpcre.so.1.2.3
7fda08c4a000-7fda08c4b000 rw-p 00069000 08:01 274629                     /usr/lib/libpcre.so.1.2.3
7fda08c4b000-7fda08c60000 r-xp 00000000 08:01 266841                     /usr/lib/libz.so.1.2.8
7fda08c60000-7fda08e5f000 ---p 00015000 08:01 266841                     /usr/lib/libz.so.1.2.8
7fda08e5f000-7fda08e60000 r--p 00014000 08:01 266841                     /usr/lib/libz.so.1.2.8
7fda08e60000-7fda08e61000 rw-p 00015000 08:01 266841                     /usr/lib/libz.so.1.2.8
7fda08e61000-7fda08ea2000 r-xp 00000000 08:01 266820                     /usr/lib/libreadline.so.6.3
7fda08ea2000-7fda090a2000 ---p 00041000 08:01 266820                     /usr/lib/libreadline.so.6.3
7fda090a2000-7fda090a4000 r--p 00041000 08:01 266820                     /usr/lib/libreadline.so.6.3
7fda090a4000-7fda090ab000 rw-p 00043000 08:01 266820                     /usr/lib/libreadline.so.6.3
7fda090ab000-7fda090ac000 rw-p 00000000 00:00 0 
7fda090ac000-7fda090c0000 r-xp 00000000 08:01 262529                     /usr/lib/libresolv-2.19.so
7fda090c0000-7fda092bf000 ---p 00014000 08:01 262529                     /usr/lib/libresolv-2.19.so
7fda092bf000-7fda092c0000 r--p 00013000 08:01 262529                     /usr/lib/libresolv-2.19.so
7fda092c0000-7fda092c1000 rw-p 00014000 08:01 262529                     /usr/lib/libresolv-2.19.so
7fda092c1000-7fda092c3000 rw-p 00000000 00:00 0 
7fda092c3000-7fda092e4000 r-xp 00000000 08:01 263661                     /usr/lib/ld-2.19.so
7fda09311000-7fda094ab000 rw-p 00000000 00:00 0 
7fda094e1000-7fda094e3000 rw-p 00000000 00:00 0 
7fda094e3000-7fda094e4000 r--p 00020000 08:01 263661                     /usr/lib/ld-2.19.so
7fda094e4000-7fda094e5000 rw-p 00021000 08:01 263661                     /usr/lib/ld-2.19.so
7fda094e5000-7fda094e6000 rw-p 00000000 00:00 0 
7fff7d564000-7fff7d585000 rw-p 00000000 00:00 0                          [stack]
7fff7d5c5000-7fff7d5c7000 r-xp 00000000 00:00 0                          [vdso]
7fff7d5c7000-7fff7d5c9000 r--p 00000000 00:00 0                          [vvar]
ffffffffff600000-ffffffffff601000 r-xp 00000000 00:00 0                  [vsyscall]
Aborted (core dumped)


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2020-12-08 13:16 UTC] cmb@php.net
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2020-12-08 13:16 UTC] cmb@php.net
Does this still happen to you with any of the actively supported
PHP versions[1]?

[1] <https://www.php.net/supported-versions.php>
 [2020-12-20 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Tue Jan 19 09:01:23 2021 UTC