emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master 72b054c: Avoid error when killing rcirc buffer


From: Lars Ingebrigtsen
Subject: [Emacs-diffs] master 72b054c: Avoid error when killing rcirc buffer
Date: Mon, 29 Jul 2019 07:31:16 -0400 (EDT)

branch: master
commit 72b054c945111f385575cfd4e678adf016b191d4
Author: Lars Ingebrigtsen <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>

    Avoid error when killing rcirc buffer
    
    * lisp/net/rcirc.el (rcirc-kill-buffer-hook): Delete the process
    in the buffer when killing server buffers to avoid triggering
    errors from the sentinel (bug#23168).
---
 lisp/net/rcirc.el | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lisp/net/rcirc.el b/lisp/net/rcirc.el
index 24084c8..5722582 100644
--- a/lisp/net/rcirc.el
+++ b/lisp/net/rcirc.el
@@ -44,6 +44,7 @@
 (require 'cl-lib)
 (require 'ring)
 (require 'time-date)
+(eval-when-compile (require 'subr-x))
 
 (defconst rcirc-id-string (concat "rcirc on GNU Emacs " emacs-version))
 
@@ -1181,6 +1182,8 @@ with it."
                rcirc-log-directory)
       (rcirc-log-write))
     (rcirc-clean-up-buffer "Killed buffer")
+    (when-let ((process (get-buffer-process (current-buffer))))
+      (delete-process process))
     (when (and rcirc-buffer-alist ;; it's a server buffer
                rcirc-kill-channel-buffers)
       (dolist (channel rcirc-buffer-alist)



reply via email to

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