Subject: Re: bug#28329: 25.2; Eshell: 40M+ output: Stack overflow in regexp matcher

From: [email-masked]
Date: Sat, 02 Sep 2017 08:30:01 -0400

Pierre Neidhardt <[email-masked]> writes:

> Today I update my Gentoo:
>
> 	> emerge --update --newuse --deep @world
>
> in Eshell.  After a very long output (40M+), the shell started stuttering and hanging, messaging the following errors on every new line of output:
>
> 	error in process filter: eshell-watch-for-password-prompt: Stack overflow in regexp matcher
> 	error in process filter: Stack overflow in regexp matcher
>
> The process became so slow it was unlikely it would ever complete, so I terminated it and had to re-run it in a *term*.

Can you get a backtrace if you M-x toggle-debug-on-error?  It would be
helpful to get a sample of output which triggers this.

Does changing the password regexp help?

    (setq eshell-password-prompt-regexp
          (format "^.\\{,80\\}%s.\\{,80\\}:\\s-*\\'"
                  (regexp-opt password-word-equivalents)))