From: caaguado at xcentra dot com
Operating system: Windows 10 64bit, Windows 7 64bi
PHP version: 7.1.0beta1
Package: mbstring related
Bug Type: Bug
Bug description:php-cgi.exe/php_mbstring.dll crash Exception 0xc0000005 Fault offset 0x00026831
Description:
------------
php-cgi.exe crash with faulting module name php_mbstring.dll, Exception
code: 0xc0000005, Fault offset: 0x00026831
Excerpt from Windows Application Event Log:
===========================================
Level Date and Time Source Event ID Task Category
Error 2016-08-01 12:57:05 Application Error 1000 (100) "Faulting
application name: php-cgi.exe, version: 7.1.0.0, time stamp: 0x57901bea
Faulting module name: php_mbstring.dll, version: 7.1.0.0, time stamp:
0x5790217b
Exception code: 0xc0000005
Fault offset: 0x00026831
(...)
Faulting application path: S:\xtack\bin\p71\php-cgi.exe
Faulting module path: S:\xtack\bin\p71\ext\php_mbstring.dll
(...)
Error 2016-08-01 12:56:55 Application Error 1000 (100) "Faulting
application name: php-cgi.exe, version: 7.1.0.0, time stamp: 0x57901bea
Faulting module name: php_mbstring.dll, version: 7.1.0.0, time stamp:
0x5790217b
Exception code: 0xc0000005
Fault offset: 0x00026831
Problem reproduced on two differen systems and Windows 64-bit editions:
1) Hewlett-Packard HP EliteBook 8460p system with 2x Intel Core i5-2540M
CPU @ 2.60GHz core(s), 8 GB RAM and Microsoft Windows 7 Enterprise
Multiprocessor Free SP1 64 bits version 6.1.7601
2) Apple Inc. MacBookAir6 2 system with 2x Intel Core i7-4650U CPU @
1.70GHz core(s), 8 GB RAM and Microsoft Windows 10 Pro Multiprocessor
Free SP0 64 bits version 10.0.10586
The crash appears both in:
a) Apache 2.4.23 (Win32, VC14, Apache Lounge binaries, see
http://www.apachelounge.com/download/). Classic
CGI interface used.
Apache shows the following entry ("trace8" trace level set) in its error
logfile:
[Mon Aug 01 19:34:22.618493 2016] [cgi:error] [pid 5764:tid 2212]
[client 127.0.0.1:49870] End of script output before headers:
php-cgi.exe
b) Nginx 1.11.2 (Win 32, official Nginx binaries for Windows, see
http://nginx.org/en/download.html).
Nginx shows the following entry ("debug" trace level set) in its error
logfile:
2016/08/01 20:03:42 [info] 2484#8068: *1 client prematurely closed
connection, so upstream connection is closed too while connecting to
upstream, client: 127.0.0.1, server: localhost, request: "GET
/docs/phpinfo.php HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host:
"127.0.0.1"
Exactly the same HTTP server stacks (Apache 2.4.23 and Nginx 1.11.2) are
used with PHP versions 7.0.9, 5.6.24 and 5.5.38, _WITHOUT_ the crash
appearing.
Test script:
---------------
When starting up Apache 2.4.23 or Nginx 1.11.2, Windows shows a "CGI /
FastCGI has stopped working" popup twice (two crashes per HTTP startup
attempt), resulting into the browser ultimately receiving a "500
Internal Server" error from the HTTP server.
The fault is new to PHP 7.1.0beta1.
According to the PHP 7.1.0beta1 news.txt changelog, the only change in
this release on mbstring is:
- Mbstring:
. Deprecated mb_ereg_replace() eval option. (Rouven WeÃling, cmb)
. Fixed bug #69151 (mb_ereg should reject ill-formed byte sequence).
(Masaki Kagaya)
Expected result:
----------------
Crash fixed and PHP 7.1.0x running flawlessly.
Actual result:
--------------
Please see attached logfiles, whose names should be pretty much
self-explanatory. If that is not the case, please kindly contact me
back, so I can assist and provide as much info as needed. Thank you.
--
Edit bug report at https://bugs.php.net/bug.php?id=72729&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=72729&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=72729&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=72729&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=72729&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=72729&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=72729&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=72729&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=72729&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=72729&r=support
Expected behavior: https://bugs.php.net/fix.php?id=72729&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=72729&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=72729&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=72729&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=72729&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=72729&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=72729&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=72729&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=72729&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=72729&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=72729&r=mysqlcfg