From dbf4266b849395808cd77ec2f12d2aa471854533 Mon Sep 17 00:00:00 2001 From: Matthias Andree Date: Fri, 12 May 2006 12:38:05 +0000 Subject: When using NTLM authentication, use regular IMAP response code handler after completing NTLM handshake, for robustness and consistency. Taken from the NetBSD portable packages collection, patch-ac. svn path=/branches/BRANCH_6-3/; revision=4825 --- imap.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'imap.c') diff --git a/imap.c b/imap.c index 856f3f86..3e3599f9 100644 --- a/imap.c +++ b/imap.c @@ -263,10 +263,8 @@ static int do_imap_ntlm(int sock, struct query *ctl) strcat(msgbuf,"\r\n"); SockWrite (sock, msgbuf, strlen (msgbuf)); - if ((result = gen_recv (sock, msgbuf, sizeof msgbuf))) - return result; - - if (strstr (msgbuf, "OK")) + result = imap_ok (sock, NULL); + if (result == PS_SUCCESS) return PS_SUCCESS; else return PS_AUTHFAIL; -- cgit v1.2.3