Carlo Teubner wrote:
> I believe I've got a patch for this (see below).
>
> First, if you look at the stacktrace in some detail in gdb, you'll see
> that this error occurs while matching regexp ".*" against the current
> filename ("" in this case) during autocmd execution. The crash occurs
> because in line 4730, 'next' is null. In line 3888, 'next' is the
> result of calling regnext(). regnext() returns NULL because global
> variable reg_toolong is TRUE. But of course the pattern ".*" is not
> too long - instead, this is left over from the evaluation of the
> previous very long regexp ("a\|a\|a...").
>
> This confusion occurs because regnext() is used both in compilation
> and evaluation of regexes. Its behaviour of returning NULL if
> reg_toolong is TRUE really only makes sense during compilation. The
> easiest way to fix it is to just set reg_toolong to FALSE before
> starting regexp evaluation, as in my patch. (It can only ever be set
> to TRUE during the compilation phase.)
Thank you very much for pinpointing the problem and making a patch.
I think it's a bit simpler to reset reg_toolong further down, then it's
needed only once.
--
hundred-and-one symptoms of being an internet addict:
124. You begin conversations with, "Who is your internet service provider?"
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ download, build and distribute -- http://www.A-A-P.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php