Probably still not fixed? http://www.mail-archive.com/tre-general@laurikari.net/msg00005.html $ gdb python GNU gdb (Gentoo 7.2 p1) 7.2 Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "i686-pc-linux-gnu". For bug reporting instructions, please see: ... Reading symbols from /usr/bin/python...done. (gdb) run tre-test.py Starting program: /usr/bin/python tre-test.py process 6666 is executing new program: /usr/bin/python2.6 [Thread debugging using libthread_db enabled] tre.Fuzzyness(delcost=1,inscost=1,maxcost=2147483647,subcost=1,maxdel=2147483647,maxerr=3,maxins=2147483647,maxsub=2147483647) Traceback (most recent call last): File "tre-test.py", line 11, in m = pt.search(data, fz) SystemError: error return without exception set Program received signal SIGSEGV, Segmentation fault. __libc_free (mem=0x706d695f) at malloc.c:3709 3709 malloc.c: No such file or directory. in malloc.c (gdb) where #0 __libc_free (mem=0x706d695f) at malloc.c:3709 #1 0xb7d9650d in __regfree (preg=0xb7c70448) at regcomp.c:646 #2 0xb7fde4e3 in PyTrePattern_dealloc (self=0xb7c70440) at tre-python.c:409 #3 0xb7ec1287 in insertdict (mp=0xb7cb424c, key=0xb7c772e0, hash=690156838, value=0xb7f87340) at Objects/dictobject.c:459 #4 0xb7ec3b31 in PyDict_SetItem (op=0xb7cb424c, key=0xb7c772e0, value=0xb7f87340) at Objects/dictobject.c:701 #5 0xb7ec5521 in _PyModule_Clear (m=0xb7c8211c) at Objects/moduleobject.c:138 #6 0xb7f2ac44 in PyImport_Cleanup () at Python/import.c:441 #7 0xb7f332cb in Py_Finalize () at Python/pythonrun.c:444 #8 0xb7f3f254 in Py_Main (argc=2, argv=0xbfffe514) at Modules/main.c:609 #9 0x080487fe in main (argc=2, argv=0xbfffe514) at ./Modules/python.c:46 (gdb) bt full #0 __libc_free (mem=0x706d695f) at malloc.c:3709 ar_ptr = p = 0x706d6957 #1 0xb7d9650d in __regfree (preg=0xb7c70448) at regcomp.c:646 dfa = #2 0xb7fde4e3 in PyTrePattern_dealloc (self=0xb7c70440) at tre-python.c:409 No locals. #3 0xb7ec1287 in insertdict (mp=0xb7cb424c, key=0xb7c772e0, hash=690156838, value=0xb7f87340) at Objects/dictobject.c:459 ep = #4 0xb7ec3b31 in PyDict_SetItem (op=0xb7cb424c, key=0xb7c772e0, value=0xb7f87340) at Objects/dictobject.c:701 hash = n_used = 8 #5 0xb7ec5521 in _PyModule_Clear (m=0xb7c8211c) at Objects/moduleobject.c:138 s = pos = 7 key = 0xb7c772e0 value = 0xb7c70440 d = 0xb7cb424c #6 0xb7f2ac44 in PyImport_Cleanup () at Python/import.c:441 pos = ndone = 1 name = key = value = 0xb7c8211c dict = interp = 0x804b008 modules = 0xb7c979bc #7 0xb7f332cb in Py_Finalize () at Python/pythonrun.c:444 interp = 0x804b008 #8 0xb7f3f254 in Py_Main (argc=2, argv=0xbfffe514) at Modules/main.c:609 c = sts = 1 command = 0x0 filename = 0xbfffe774 "tre-test.py" module = 0x0 fp = p = 0x0 unbuffered = 1 skipfirstline = 0 stdin_is_interactive = 1 help = 1 version = 1 saw_unbuffered_flag = 1 cf = {cf_flags = 0} target_script_name = 0x0 #9 0x080487fe in main (argc=2, argv=0xbfffe514) at ./Modules/python.c:46 process_name = 0x0 (gdb) $ cat tre-test.py #! /usr/bin/python import tre pt = tre.compile("gaaggcacncaggggataggn", tre.EXTENDED) data='gactGGCAAGCTCGCTTGATCTTGATTTCTAGATGAGTACAGACGTCGAAGACGGCGTCGACATCTCTGGCTTTGGTTCTAGCAGAGTGTCXgaaagtagtacgtggaggcgaaggcacncaggggataggn' fz = tre.Fuzzyness(maxerr = 3) print fz m = pt.search(data, fz) if m: print m.groups() print m[0] $