From d9d18e535ec77c1ac63a95fdcc6a107b099b1b06 Mon Sep 17 00:00:00 2001 From: czkmt Date: Fri, 10 Dec 1999 10:04:08 +0000 Subject: [PATCH] (read-pw-set-mail-source-passwd-cache): Ignore non-POP mail sources. --- lisp/read-passwd.el | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/lisp/read-passwd.el b/lisp/read-passwd.el index d99e37d..ae7a239 100644 --- a/lisp/read-passwd.el +++ b/lisp/read-passwd.el @@ -90,16 +90,17 @@ Argument PROMPT ." (if (not mail-source-password-cache) (car (mapcar (lambda (x) - (mail-source-bind (pop x) - (let ((from (format "%s:%s:%s" server user port)) - (mail-source-string - (format "pop:%s@%s" user server))) - (setq pw (read-pw-return-passwd-string user server)) - (unless (assoc user mail-source-password-cache) - (set-alist 'mail-source-password-cache - (format "%s:%s:%s" server user port) - pw)) - (cdr (assoc from mail-source-password-cache))))) + (when (eq 'pop (car x)) + (mail-source-bind (pop x) + (let ((from (format "%s:%s:%s" server user port)) + (mail-source-string + (format "pop:%s@%s" user server))) + (setq pw (read-pw-return-passwd-string user server)) + (unless (assoc user mail-source-password-cache) + (set-alist 'mail-source-password-cache + (format "%s:%s:%s" server user port) + pw)) + (cdr (assoc from mail-source-password-cache)))))) mail-sources)))) ;; ;; -- 1.7.10.4