aboutsummaryrefslogtreecommitdiffstats
path: root/imap.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2001-03-22 21:26:14 +0000
committerEric S. Raymond <esr@thyrsus.com>2001-03-22 21:26:14 +0000
commite0dc5edc9eee1c0c15dde22b6cbebe6a46384732 (patch)
tree1c66b9bcc546ff2c95872393c65fa96bf4ff7d74 /imap.c
parentd06cff3068d9718782dace3830eace460b2e8428 (diff)
downloadfetchmail-e0dc5edc9eee1c0c15dde22b6cbebe6a46384732.tar.gz
fetchmail-e0dc5edc9eee1c0c15dde22b6cbebe6a46384732.tar.bz2
fetchmail-e0dc5edc9eee1c0c15dde22b6cbebe6a46384732.zip
Nalin's GSSAPI post.
svn path=/trunk/; revision=3271
Diffstat (limited to 'imap.c')
-rw-r--r--imap.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/imap.c b/imap.c
index be2fcd5b..915ed920 100644
--- a/imap.c
+++ b/imap.c
@@ -299,7 +299,10 @@ static int imap_getauth(int sock, struct query *ctl, char *greeting)
if ((ctl->server.authenticate == A_ANY
|| ctl->server.authenticate==A_GSSAPI)
&& strstr(capabilities, "AUTH=GSSAPI"))
- return(do_gssauth(sock, "AUTHENTICATE", ctl->server.truename, ctl->remotename));
+ if(!(ok = do_gssauth(sock, "AUTHENTICATE", ctl->server.truename, ctl->remotename)))
+ {
+ return ok;
+ }
#endif /* GSSAPI */
#ifdef KERBEROS_V4
@@ -308,7 +311,7 @@ static int imap_getauth(int sock, struct query *ctl, char *greeting)
|| ctl->server.authenticate==A_KERBEROS_V5)
&& strstr(capabilities, "AUTH=KERBEROS_V4"))
{
- if ((ok = do_rfc1731(sock, "AUTHENTICATE", ctl->server.truename)))
+ if (!(ok = do_rfc1731(sock, "AUTHENTICATE", ctl->server.truename)))
/* SASL cancellation of authentication */
gen_send(sock, "*");
return(ok);