If we don't find a match, don't bug out on non-bound variables.
authorLars Ingebrigtsen <larsi@gnus.org>
Fri, 18 Feb 2011 22:07:53 +0000 (14:07 -0800)
committerLars Ingebrigtsen <larsi@gnus.org>
Fri, 18 Feb 2011 22:08:08 +0000 (14:08 -0800)
lisp/ChangeLog
lisp/auth-source.el

index 49764d1..67faeac 100644 (file)
@@ -2,6 +2,8 @@
 
        * auth-source.el (auth-source-search): Don't try to create credentials
        if the caller doesn't want that.
+       (auth-source-search): If we don't find a match, don't bug out on
+       non-bound variables.
 
        * nnimap.el (nnimap-log-command): Add a newline to the inhibited
        logging.
index 6e6f962..64d244b 100644 (file)
@@ -554,14 +554,15 @@ must call it to obtain the actual value."
       ;; create the entries.
       (when (and create
                 (not matches))
-       (let ((match (apply
-                     (slot-value backend 'search-function)
-                     :backend backend
-                     :create create
-                     :delete delete
-                     spec)))
-         (when match
-           (push (list backend match) matches))))
+       (dolist (backend filtered-backends)
+         (let ((match (apply
+                       (slot-value backend 'search-function)
+                       :backend backend
+                       :create create
+                       :delete delete
+                       spec)))
+           (when match
+             (push (list backend match) matches)))))
 
       (setq backend (caar matches)
            found-here (cadar matches))