From c9556092eaa4eadd2fb34284f08bbf5945ab5658 Mon Sep 17 00:00:00 2001 From: yamaoka Date: Sat, 13 Mar 2004 00:30:23 +0000 Subject: [PATCH] Synch to No Gnus 200403121916. --- lisp/ChangeLog | 6 ++++++ lisp/imap.el | 12 +++++++++--- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7919fea..64e6dbe 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2004-03-12 Reiner Steib + + * imap.el (imap-store-password): New variable. + (imap-interactive-login): Use it. + Suggested by Mark Plaksin . + 2004-03-12 Katsumi Yamaoka * gnus-art.el (gnus-article-read-summary-keys): Restore new diff --git a/lisp/imap.el b/lisp/imap.el index ea69dff..56a7e67 100644 --- a/lisp/imap.el +++ b/lisp/imap.el @@ -262,6 +262,11 @@ Shorter values mean quicker response, but is more CPU intensive." :type 'number :group 'imap) +(defcustom imap-store-password nil + "If non-nil, store session password without promting." + :group 'imap + :type 'boolean) + ;; Various variables. (defvar imap-fetch-data-hook nil @@ -811,9 +816,10 @@ Returns t if login was successful, nil otherwise." (progn (setq ret t imap-username user) - (if (and (not imap-password) - (y-or-n-p "Store password for this session? ")) - (setq imap-password passwd))) + (when (and (not imap-password) + (or imap-store-password + (y-or-n-p "Store password for this session? "))) + (setq imap-password passwd))) (message "Login failed...") (setq passwd nil) (setq imap-password nil) -- 1.7.10.4