diff options
author | Teodor Zlatanov <tzz@lifelogs.com> | 2011-02-25 23:52:19 +0000 |
---|---|---|
committer | Katsumi Yamaoka <yamaoka@jpl.org> | 2011-02-25 23:52:19 +0000 |
commit | 61e9662ef52e9b4a257fc9dd3c3812af2657f70a (patch) | |
tree | a84d4be6c56c9ed602cbe73ff675f73da45ef84f /lisp/password-cache.el | |
parent | 4ad89555139cef8136f98c7bd1ab83bf003ef5e4 (diff) | |
download | emacs-61e9662ef52e9b4a257fc9dd3c3812af2657f70a.tar.gz |
Merge changes made in Gnus trunk.
auth-source.el (auth-source-search): Cache empty result sets.
password-cache.el (password-in-cache-p): Convenience function to check if a key is in the cache, even if the value is nil.
Diffstat (limited to 'lisp/password-cache.el')
-rw-r--r-- | lisp/password-cache.el | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lisp/password-cache.el b/lisp/password-cache.el index 8738aa65a9f..a7f75a03add 100644 --- a/lisp/password-cache.el +++ b/lisp/password-cache.el @@ -76,6 +76,12 @@ regulate cache behavior." key (symbol-value (intern-soft key password-data)))) +(defun password-in-cache-p (key) + "Check if KEY is in the cache." + (and password-cache + key + (intern-soft key password-data))) + (defun password-read (prompt &optional key) "Read password, for use with KEY, from user, or from cache if wanted. KEY indicate the purpose of the password, so the cache can |