emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master d0ebc38: Avoid infinitly looping in tramp-interrupt


From: Michael Albinus
Subject: [Emacs-diffs] master d0ebc38: Avoid infinitly looping in tramp-interrupt-process (bug#35506)
Date: Wed, 15 May 2019 10:30:07 -0400 (EDT)

branch: master
commit d0ebc389ebba0ca5b99e019c47c4a616941378ac
Author: John Shahid <address@hidden>
Commit: Michael Albinus <address@hidden>

    Avoid infinitly looping in tramp-interrupt-process (bug#35506)
    
    * lisp/net/tramp.el (tramp-interrupt-process): Remove with-timeout.
    Instead pass a timeout to tramp-accept-process-output.
    tramp-accept-process-output stops timers from running which makes the
    with-timeout ineffective.
---
 lisp/net/tramp.el | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el
index 0a3129f..2aa62eb 100644
--- a/lisp/net/tramp.el
+++ b/lisp/net/tramp.el
@@ -4861,10 +4861,9 @@ Only works for Bourne-like shells."
         (format "kill -2 -%d" pid))
        ;; Wait, until the process has disappeared.  If it doesn't,
        ;; fall back to the default implementation.
-       (with-timeout (1 (ignore))
-         (while (tramp-accept-process-output proc))
-         ;; Report success.
-         proc)))))
+        (and (tramp-accept-process-output proc 1)
+            ;; Report success.
+            proc)))))
 
 ;; `interrupt-process-functions' exists since Emacs 26.1.
 (when (boundp 'interrupt-process-functions)



reply via email to

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