From f6dcf14c70aac1b1c240f0bae4174612b110cf1c Mon Sep 17 00:00:00 2001 From: Michael Welsh Duggan Date: Mon, 21 Mar 2011 21:09:34 -0400 Subject: [PATCH 3/3] Allow capabilities to be set after login --- lisp/nnimap.el | 8 +++++++- 1 files changed, 7 insertions(+), 1 deletions(-) diff --git a/lisp/nnimap.el b/lisp/nnimap.el index 138875b..b92c4c8 100644 --- a/lisp/nnimap.el +++ b/lisp/nnimap.el @@ -395,7 +395,13 @@ textual parts.") (let ((nnimap-inhibit-logging t)) (setq login-result (nnimap-login (car credentials) (cadr credentials)))) - (unless (car login-result) + (if (car login-result) + ;; See if capability is set as part of login + ;; response + (dolist (response (cddr login-result)) + (when (string= "CAPABILITY" (upcase (car response))) + (setf (nnimap-capabilities nnimap-object) + (mapcar #'upcase (cdr response))))) ;; If the login failed, then forget the credentials ;; that are now possibly cached. (dolist (host (list (nnoo-current-server 'nnimap) -- 1.7.4.1