GNU bug report logs - #33747
26.1; process-send-string exceeds max-specpdl-size

Previous Next

Package: emacs;

Reported by: Markus Triska <triska <at> metalevel.at>

Date: Fri, 14 Dec 2018 17:51:02 UTC

Severity: normal

Found in version 26.1

Full log


View this message in rfc822 format

From: Markus Triska <triska <at> metalevel.at>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 33747 <at> debbugs.gnu.org
Subject: bug#33747: 26.1; process-send-string exceeds max-specpdl-size
Date: Fri, 14 Dec 2018 22:23:16 +0100
Eli Zaretskii <eliz <at> gnu.org> writes:

> stopping everything else, so waiting for input from any source makes
> perfect sense to me.

In this concrete case, I am looking for a way to make Emacs not wait
for, or at least not process, input from a specific process while
sending output to a different process.

For the case I posted, I can alleviate the issue a bit if I set:

    (setq max-specpdl-size 5000)

However, if I then use for example the following definition of
send-to-target instead of the one I posted:

   (defun send-to-target (proc str)
     (if (process-live-p target)
         (process-send-string target str)
       (kill-process source)))

then I get, for the receipe I posted:

    Lisp nesting exceeds ‘max-lisp-eval-depth’

This is unfortunate, because increasing this limit will eventually crash
Emacs. The root cause is that process-send-string triggers the filter of
the same process that caused the filter to be invoked. I find this
unexpected, because the target process is different, and if possible, I
would like a way do prevent this. Could you please consider adding a
feature that prevents triggering the filter in such cases?

Thank you and all the best!
Markus






This bug report was last modified 6 years and 280 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.