Edit report at https://bugs.php.net/bug.php?id=61644&edit=1
ID: 61644 Comment by: pio at rdl dot pl Reported by: pio at rdl dot pl Summary: crashes with preg_match Status: Open Type: Bug Package: Regexps related Operating System: Debian 6 PHP Version: 5.3.10 Block user comment: N Private report: N New Comment: The file 1.txt here is http://speedy.sh/YGJDR/1.txt Previous Comments: ------------------------------------------------------------------------ [2012-04-05 21:31:32] pio at rdl dot pl Description: ------------ Hello ! We have problem with parse some data and regular expression match. I have attached the file 1.txt # /usr/local/php5.3/bin/php test.php Segmentation fault (gdb) run test.php Starting program: /usr/local/bin/php test.php [Thread debugging using libthread_db enabled] [New Thread 0x7f1659abb710 (LWP 14776)] Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7f1659abb710 (LWP 14776)] 0x00000000004bf9ff in match ( eptr=0x1632378 "nteria.pl;;\[email protected];;\[email protected];;\[email protected];;\[email protected];;\[email protected];;\[email protected];;\[email protected];;\[email protected]"..., ecode=0x165916a "V", mstart=0x1630b08 "status=OK\[email protected];;\[email protected];;\[email protected];;\[email protected];;\[email protected];;\[email protected];;\[email protected];;\na.karamon"..., markptr=0x0, offset_top=8, md=0x7fff797e7960, ims=0, eptrb=0x0, flags=0, rdepth=12461) at /usr/local/directadmin/custombuild/php-5.2.17/ext/pcre/pcrelib/pcre_exec.c:1552 1552 /usr/local/directadmin/custombuild/php-5.2.17/ext/pcre/pcrelib/pcre_exec.c: No such file or directory. in /usr/local/directadmin/custombuild/php-5.2.17/ext/pcre/pcrelib/pcre_exec.c (gdb) print (char *)(executor_globals.function_state_ptr->function)->common.function_name $1 = 0x89f727 "preg_match" regards, Piotr Test script: --------------- <?php $matches = array(); $data = file_get_contents('1.txt'); var_dump(preg_match('/^(.|\s)+?subscribers-exported=((.|\s)+)$/', $data, $matches)); Expected result: ---------------- int(0) Actual result: -------------- crash ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=61644&edit=1
