go to bug id or search bugs for
We have a regular expression that removed nested comments from an HTML string. It was working OK in PHP 5.3 and 5.5 but crashes in PHP 5.6.20 and 5.6.22
The included test script is a very cut down version of string being processed. The number of characters seems to be important, removing some characters from the class names will make the script run but I can't figure the logic of it.
PHP crashes without outputting any errors, I only have the Windows Event Log output:
Faulting application name: httpd.exe, version: 188.8.131.52, time stamp: 0x550eaef9
Faulting module name: php5ts.dll, version: 184.108.40.206, time stamp: 0x57468b87
Exception code: 0xc00000fd
Fault offset: 0x0011ddd2
Faulting process id: 0x1600
Faulting application start time: 0x01d1c0c7b01411c2
Faulting application path: C:\Apache24\bin\httpd.exe
Faulting module path: C:\php-5.6.22\php5ts.dll
Report Id: 23060e48-35e8-41c0-96e7-f75628bdf8f9
Faulting package full name:
Faulting package-relative application ID:
$html = <<<EOT
$html = preg_replace("/<!--(?(?!<!--).)*-->/sU", '', $html, -1, $count);
} while ($count);
Site can't be reached error
Add a Patch
Add a Pull Request
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.
I can't reproduce the issue on Windows 10 with the official
php-5.6.22-nts-Win32-VC11-x64 nor on <https://3v4l.org/s6jQ7>.
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.