bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#24358: 25.1.50; re-search-forward errors with "Variable binding dept


From: Eli Zaretskii
Subject: bug#24358: 25.1.50; re-search-forward errors with "Variable binding depth exceeds max-specpdl-size"
Date: Mon, 24 Oct 2016 19:13:15 +0300

> From: Noam Postavsky <npostavs@users.sourceforge.net>
> Date: Mon, 24 Oct 2016 11:33:11 -0400
> Cc: 24358@debbugs.gnu.org, Sam Halliday <sam.halliday@gmail.com>
> 
> > What bothers me is this: could it be that relocation happens between
> > the first and the second line above?  If it can, then what
> > POINTER_TO_OFFSET does will be inconsistent with the base address at
> > the time regstart[*p] was assigned the value of d.
> >
> > The code runs in a loop, or so it seems, so it's hard to reason about
> > time sequences.
> 
> Oh, I see. Yes, I think you're right, the pointers stored in regstart,
> regend, and fail_stack could become inconsistent. Hard to say what
> kind of regex could trigger it, but it seems quite possible.

Maybe we should simply call r_alloc_inhibit_buffer_relocation around
any calls to regex.c functions, and remove the code you wrote to
handle relocations internally.

I'm sorry I didn't look at this closer before, and thus caused you to
work on all those changes, which we might now need to revert.





reply via email to

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