[ python-Bugs-1072259 ] re module segfaulting in large regular expression

SourceForge.net noreply at sourceforge.net
Wed Dec 1 00:57:14 CET 2004


Bugs item #1072259, was opened at 2004-11-23 22:38
Message generated for change (Comment added) made by edemaine
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1072259&group_id=5470

Category: Extension Modules
Group: Python 2.4
Status: Open
Resolution: None
Priority: 5
Submitted By: Erik Demaine (edemaine)
Assigned to: Nobody/Anonymous (nobody)
Summary: re module segfaulting in large regular expression

Initial Comment:
The attached code worked fine in Python 2.3 and prior,
but broke in a recent version of Python 2.4 (I think
between the alpha and beta, but I'm not sure).  It now
causes a Segmentation fault, at least on my Linux boxes
(2.4.18 and 2.4.22).

For those not looking at the attachment, the code is
essentially:
import re
re.match (...big regular expression..., 'December 20,
1997', re.IGNORECASE)

The code works if the re.IGNORECASE flag is omitted.
I hope I'm not doing anything stupid in installation...
I tried both CVS head and 2.4c1, both with-pyalloc and
without-pyalloc.

----------------------------------------------------------------------

>Comment By: Erik Demaine (edemaine)
Date: 2004-11-30 18:57

Message:
Logged In: YES 
user_id=265183

FYI, this bug remains in 2.4final, which is a shame to me
(but probably just a timing mishap), as it makes 2.4
unusable to me.

However, the exact version I attached before does seem to
work on on 2.4final on WindowsXP, but still not on Linux. 
Attached is a version that still fails on 2.4final on all
systems I've tried.  The only difference is using
re.compile(...).match instead of re.match.

----------------------------------------------------------------------

Comment By: Erik Demaine (edemaine)
Date: 2004-11-23 22:40

Message:
Logged In: YES 
user_id=265183

An update: The same code crashes (general protection fault)
on a vanilla install of 2.4c1 on Windows XP using the MSI
installer.  So I don't think it's my installation.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1072259&group_id=5470


More information about the Python-bugs-list mailing list