diff lisp/gnus/nnimap.el @ 111401:733acab855e4

Merge changes made in Gnus trunk. mm-decode.el (mm-save-part): Put the entire path in the `M-n' slot. nnimap.el (nnimap-find-article-by-message-id): Don't EXAMINE a group if it's already selected. gnus.texi (Customizing the IMAP Connection): Document `nnimap-expunge' and remove `nnimap-expunge-inbox' from example. gnus.texi (Customizing the IMAP Connection): Remove nnir mention, since that works by default. gnus-sum.el (gnus-summary-show-article): Take `t' as the arg to mean "raw". gnus-html.el (gnus-html-browse-url): Implement mailto: URLs. shr.el (shr-browse-url): Implement mailto: URLs. nnir.el, gnus-sum.el: Improve thread-referral. message.el (message-send-mail): Use the value of message-courtesy-message from the message buffer.
author Katsumi Yamaoka <yamaoka@jpl.org>
date Thu, 04 Nov 2010 22:18:09 +0000
parents 0c7c9736f766
children b75e6634a171
line wrap: on
line diff
--- a/lisp/gnus/nnimap.el	Thu Nov 04 11:22:12 2010 -0700
+++ b/lisp/gnus/nnimap.el	Thu Nov 04 22:18:09 2010 +0000
@@ -731,8 +731,6 @@
       ;; to examine a mailbox that doesn't exist.  This seems to be
       ;; the only way that allows us to reliably go back to unselected
       ;; state on Courier.
-      (nnimap-command "EXAMINE DOES.NOT.EXIST")
-      (setf (nnimap-group nnimap-object) nil)
       (car (nnimap-command "RENAME %S %S"
 			   (utf7-encode group t) (utf7-encode new-name t))))))
 
@@ -863,8 +861,9 @@
 (defun nnimap-find-article-by-message-id (group message-id)
   (with-current-buffer (nnimap-buffer)
     (erase-buffer)
-    (setf (nnimap-group nnimap-object) nil)
-    (nnimap-send-command "EXAMINE %S" (utf7-encode group t))
+    (unless (equal group (nnimap-group nnimap-object))
+      (setf (nnimap-group nnimap-object) nil)
+      (nnimap-send-command "EXAMINE %S" (utf7-encode group t)))
     (let ((sequence
 	   (nnimap-send-command "UID SEARCH HEADER Message-Id %S" message-id))
 	  article result)