php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #20769 regex hangs php if --with-system-regex turned on
Submitted: 2002-12-02 13:23 UTC Modified: 2002-12-02 13:30 UTC
From: robert dot penz at outertech dot com Assigned:
Status: Not a bug Package: Regexps related
PHP Version: 4.2.3 OS: linux debian-woody
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
24 - 24 = ?
Subscribe to this entry?

 
 [2002-12-02 13:23 UTC] robert dot penz at outertech dot com
ereg( '^[a-z0-9_\-\.]+@[a-z0-9_\-\.]+\.[a-z0-9]+',   
'me@some.where', $bla);   
   
does hang with 100% cpu&mem so the kernel kills it   
   
Dec  2 17:49:51 whitestar kernel: Out of Memory: Killed   
process 6176 (apache).   
   
it happens only if I compile with --with-system-regex  
 
after I figured that out, I stopped investigating deeper .. 
I don't know if its a debian or php problem ... but I 
though I report it anyway. 

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-12-02 13:25 UTC] derick@php.net
That configure option doesn't exist; in case you mean --with-regex=system, read ./configure --help:

--with-regex=TYPE
regex library type: system, apache, php. Default: php
WARNING: Do NOT use unless you know what you are doing!

You should not touch this unless you know what you're doing, and my guess is that you have clue what this is for.

Not a bug -> bogus
 [2002-12-02 13:30 UTC] robert dot penz at outertech dot com
i used that for compiling and I didn't get an error  
message, and it hangs.   
   
   
 ./configure --with-gmp --enable-ftp --with-zlib\   
        --enable-bcmath --enable-sysvsem --enable-sysvshm   
--enable-calendar\   
        --enable-trans-sid --enable-versioning   
--enable-track-vars\   
        --enable-inline-optimization   
--with-config-file-path=/etc/php4\   
        --enable-readline --with-pam --with-gettext\   
        --with-gdbm --with-mysql --with-apxs\   
        --with-xml --with-sablot --with-xslt-sablot\   
        --enable-xslt --enable-force-cgi-redirect   
--with-system-regex\   
        --with-dom --enable-mcrypt --with-mhash   
   
I changed it to   
 
./configure --with-gmp --enable-ftp --with-zlib\ 
        --enable-bcmath --enable-sysvsem --enable-sysvshm 
--enable-calendar\ 
        --enable-trans-sid --enable-versioning 
--enable-track-vars\ 
        --enable-inline-optimization 
--with-config-file-path=/etc/php4\ 
        --with-gdbm --with-mysql --with-apxs\ 
        --with-xml --with-sablot --with-xslt-sablot\ 
        --enable-xslt --enable-force-cgi-redirect \ 
        --with-dom --enable-mcrypt --with-mhash 
 
and now it works
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 15:01:28 2024 UTC