[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#34910: 27.0.50; Too much matching reentrancy

From: Mattias Engdegård
Subject: bug#34910: 27.0.50; Too much matching reentrancy
Date: Tue, 19 Mar 2019 13:25:13 +0100
User-agent: Evolution 3.30.5 (3.30.5-1.fc29)

tis 2019-03-19 klockan 12:01 +0200 skrev Eli Zaretskii:
> I don't know yet.  I asked you to elaborate on the reasons for your
> expectations, and I still hope you will humor me.  Because just
> taking the problem's manifestations at face value, one could argue
> that the precise error message is immaterial, as long as it points to
> the right direction, and "stack overflow in regexp matcher" is as
> obscure as the other message.  But maybe I'm missing something, which
> is why I asked you to elaborate on your reasoning.

Sorry, I didn't mean to sound touchy! Being the bug reporter, I deserve
every probing question. I'm most grateful for your quick reply!

It turns out the regexp cache logic is broken: it always uses the last
(LRU) entry, and fails if that entry is busy. It should really use the
last free entry.

What happened was that a regexp failed because of stack overflow, which
caused lots of code to run and many regexps to be compiled, but the
original (failing) regexp was still marked busy in the cache.
Eventually, it had been pushed down to the last position in the cache,
where it caused the next request for a free cache entry to fail with
the reentrancy error.

This patch fixes it. Please review.

Attachment: 0001-Fix-spurious-regexp-reentrancy-error.patch
Description: Text Data

reply via email to

[Prev in Thread] Current Thread [Next in Thread]