Bug #16976 Updated: preg_replace /e causes access violation

From: Date: Tue, 04 Jun 2002 08:28:52 +0000
Subject: Bug #16976 Updated: preg_replace /e causes access violation
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-9424@lists.php.net to get a copy of this message
ID: 16976 Updated by: mfischer@php.net Reported By: sean@caedmon.net -Status: Open +Status: Bogus Bug Type: Regexps related Operating System: Windows2000 / IIS5 PHP Version: 4.1.2 New Comment: Thank you for taking the time to report a problem with PHP. Unfortunately your version of PHP is too old -- the problem might already be fixed. Please download a new PHP version from http://www.php.net/downloads.php If you are able to reproduce the bug with one of the latest versions of PHP, please change the PHP version on this bug report to the version you tested and change the status back to "Open". Again, thank you for your continued support of PHP. Previous Comments: ------------------------------------------------------------------------ [2002-05-02 16:36:54] sean@caedmon.net this code causes an access violation on IIS5/Windows2000/PHP4.1.2 Reports are that it works fine with apache4.0.6 (OS unknown): <?php $str = "here's some code:\n [code]//yep;\n \$a = 0; if (\$a < 1) { echo 'moo &amp;'; }\n[/code]"; $str = preg_replace('/(\[code\])([^\[]*)(\[\/code\])/ie', "'<br><br>code:<hr size=\"1\"><pre>' . htmlspecialchars('\\2') . '<hr size=\"1\"></pre>'", $str); echo $str; ?> S ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=16976&edit=1

« previous php.bugs (#9424) next »