Python Coredump on FreeBSD

Bengt Richter bokr at oz.net
Fri May 16 12:45:21 EDT 2003


On Fri, 16 May 2003 08:14:19 +0200, "Harald Schneider" <h_schneider at marketmix.com> wrote:
<top_post_moved />
>"Fredrik Lundh" <fredrik at pythonware.com> schrieb im Newsbeitrag
>news:mailman.1053034886.23483.python-list at python.org...
>> Harald Schneider wrote:
>>
>> > The file is read completely and split into lines. Each line is split by
>the
>> > ":". Comments # are ignored.
>>
>> try replacing every ".*?" with ".*".  no matter what engine you
>> use, that will require less memory, and probably also run faster.
>>
>> </F>
<was_top_post attitude=";-)" >
>Thanks - Isn't this "greedy" then ?
>
>--Harald
>
</was_top_post>

I guess the point is, if there is a greedy match, there must be at least one
non-greedy match, even if they aren't the same sometimes, and since you are
not using the actual match data, it shouldn't make a difference?

To get a minimal test example, perhaps you could easily write (always flushing)
a log file of patterns and strings in successive line pairs, before each test,
and then see what it was working on when it crashed, by looking at the last two
lines of the file?

Then test that pattern and string in isolation, to see if it is a particular call
that does it vs some cumulative effect of the loop? If it crashes in isolation,
it would make a good example for a bug report, IWT. (Would you also post the
pattern & string ;-)

Just a thought.

Regards,
Bengt Richter




More information about the Python-list mailing list