Bug #1666: ereg_replace causes a segfault
| From: | rsteffen at ia dot net | Date: | Tue, 06 Jul 1999 05:18:10 +0000 |
| Subject: | Bug #1666: ereg_replace causes a segfault | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-8111@lists.php.net to get a copy of this message | ||
From: rsteffen@ia.net
Operating system: Red Hat Linux 6.0
PHP version: 3.0.11
PHP Bug Type: Reproduceable crash
Bug description: ereg_replace causes a segfault
The following script causes PHP 3.0.11 to segfault predictably.
<HTML>
<?
$string1 = "This is a test";
echo( "$string1<BR>" );
$string2 = ereg_replace( " is", " was", $string1 );
echo( "$string2<BR>" );
?>
</HTML>
Commenting out the ereg_replace stops the segfault. Works fine on 3.0.9 and 3.0.8. I can't find
a copy of 3.0.10
to try it there.
Configuration:
PHP is compiled as an Apache module with the following
config:
./configure --prefix=/usr \
--with-apxs=/usr/sbin/apxs \
--with-config-file-path=/usr/lib \
--enable-debug=no \
--enable-safe-mode \
--with-exec-dir=/usr/bin \
--with-system-regex \
--with-imap=imap-4.5/c-client \
--with-sybase-ct=/opt/sybase \
--with-ldap=yes \
--enable-track-vars \
--enable-debugger \
--enable-sysvsem \
--enable-sysvshm \
--with-yp \
--with-zlib \
--with-db2 \
--with-gdbm
I am working on a stack trace, but apache isn't cooperating tonight.