--- lib/url.c +++ lib/url.c @@ -1767,7 +1767,7 @@ ConnectionExists(struct SessionHandle *d } if((needle->protocol & PROT_FTP) || ((needle->protocol & PROT_HTTP) && - (needle->data->state.authhost.want==CURLAUTH_NTLM))) { + (needle->data->state.authhost.want & CURLAUTH_NTLM))) { /* This is FTP or HTTP+NTLM, verify that we're using the same name and password as well */ if(!strequal(needle->user, check->user) ||