]> granicus.if.org Git - mutt/commitdiff
The attached patch causes mutt to attempt the next method in
authorBrendan Cully <brendan@kublai.com>
Mon, 16 Aug 2004 21:36:06 +0000 (21:36 +0000)
committerBrendan Cully <brendan@kublai.com>
Mon, 16 Aug 2004 21:36:06 +0000 (21:36 +0000)
imap_authenticators if the previous method failed, even if the server
reported that the method was available. Previously mutt would give up
if any authentication method failed.

imap/auth_sasl.c

index c55cdcc1902d0d6dd91fb70be4ce8bfe60b58f16..a68c9d427b4d6e10167e51aa6a4c99eab31b89f2 100644 (file)
@@ -122,6 +122,13 @@ imap_auth_res_t imap_auth_sasl (IMAP_DATA* idata, const char* method)
       irc = imap_cmd_step (idata);
     while (irc == IMAP_CMD_CONTINUE);
 
+    if (method && irc == IMAP_CMD_NO)
+    {
+      dprint (2, (debugfile, "imap_auth_sasl: %s failed\n", method));
+      sasl_dispose (&saslconn);
+      return IMAP_AUTH_UNAVAIL;
+    }
+
     if (irc == IMAP_CMD_BAD || irc == IMAP_CMD_NO)
       goto bail;