emacs-bug-tracker
[Top][All Lists]
Advanced

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

[debbugs-tracker] bug#23700: closed (Patch to fix erc-kill-channel sendi


From: GNU bug Tracking System
Subject: [debbugs-tracker] bug#23700: closed (Patch to fix erc-kill-channel sending command to server when no connection)
Date: Tue, 18 Apr 2017 00:33:02 +0000

Your message dated Mon, 17 Apr 2017 20:32:11 -0400
with message-id <address@hidden>
and subject line Re: bug#23700: Patch to fix erc-kill-channel sending command 
to server when no connection
has caused the debbugs.gnu.org bug report #23700,
regarding Patch to fix erc-kill-channel sending command to server when no 
connection
to be marked as done.

(If you believe you have received this mail in error, please contact
address@hidden)


-- 
23700: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=23700
GNU Bug Tracking System
Contact address@hidden with problems
--- Begin Message --- Subject: Patch to fix erc-kill-channel sending command to server when no connection Date: Sun, 5 Jun 2016 17:47:58 +0000 (UTC) User-agent: Loom/3.14 (http://gmane.org/)
In the latest Emacs sources, function erc-default-target returns
nil when ERC is no longer connected to the server for the current
ERC buffer.  This can cause erc-kill-channel to try to send a
command to the disconnected server when a channel buffer is killed.
This patch fixes that.
--
Fran Litterio


diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el
index 8501e2c..da5edf1 100644
--- a/lisp/erc/erc.el
+++ b/lisp/erc/erc.el
@@ -6735,9 +6735,10 @@ This function should be on `erc-kill-server-hook'."
 This function should be on `erc-kill-channel-hook'."
   (when (erc-server-process-alive)
     (let ((tgt (erc-default-target)))
-      (erc-server-send (format "PART %s :%s" tgt
-                               (funcall erc-part-reason nil))
-                       nil tgt))))
+      (if tgt
+         (erc-server-send (format "PART %s :%s" tgt
+                                  (funcall erc-part-reason nil))
+                          nil tgt)))))
 
 ;;; Dealing with `erc-parsed'
 





--- End Message ---
--- Begin Message --- Subject: Re: bug#23700: Patch to fix erc-kill-channel sending command to server when no connection Date: Mon, 17 Apr 2017 20:32:11 -0400 User-agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/)
Version: 26.1

Thanks, applied as 4ad6be6.


--- End Message ---

reply via email to

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