Bug #60419 [Com]: PCRE segfault

From: Date: Wed, 30 Nov 2011 16:27:45 +0000
Subject: Bug #60419 [Com]: PCRE segfault
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-165589@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=60419&edit=1 ID: 60419 Comment by: mikemc-phpbug at terabytemedia dot com Reported by: mikemc-phpbug at terabytemedia dot com Summary: PCRE segfault Status: Open Type: Bug Package: PCRE related Operating System: linux PHP Version: 5.3.8 Block user comment: N Private report: N New Comment: Removing the "\s?" from the pattern alleviates the issue (no crashing), but of course, then the pattern does not serve a purpose for me. Previous Comments: ------------------------------------------------------------------------ [2011-11-30 16:23:21] mikemc-phpbug at terabytemedia dot com Description: ------------ Tested this on my custom built 5.3.8 and the standard 5.3.8 that ships with FC 15 - same result in both so I assume it is not specific to my build. Run the test code - it will segfault. Not sure if this is PHP related (PHP hooks into PCRE) or solely lives inside PCRE. Test script: --------------- <?php $input = " ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. ................................................................................................................................................................................................. "; echo preg_replace('/(\.\s?){3,}/', '...', $input); Expected result: ---------------- Not to dump core Actual result: -------------- Dumped core ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=60419&edit=1

« previous php.bugs (#165589) next »