]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
POP3: when USER command fails, don't even try PASS
authorDaniel Stenberg <daniel@haxx.se>
Fri, 16 Apr 2010 20:56:13 +0000 (22:56 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Fri, 16 Apr 2010 20:56:13 +0000 (22:56 +0200)
lib/pop3.c

index 4894f3c44c8476ede19db28e0a059318d9274a9a..34c6fdfb1300c0856cd07d8d2006e5e23c1e8b42 100644 (file)
@@ -311,10 +311,10 @@ static CURLcode pop3_state_user_resp(struct connectdata *conn,
     failf(data, "Access denied. %c", pop3code);
     result = CURLE_LOGIN_DENIED;
   }
-
-  /* send PASS */
-  result = Curl_pp_sendf(&conn->proto.pop3c.pp, "PASS %s",
-                         pop3->passwd?pop3->passwd:"");
+  else
+    /* send PASS */
+    result = Curl_pp_sendf(&conn->proto.pop3c.pp, "PASS %s",
+                           pop3->passwd?pop3->passwd:"");
   if(result)
     return result;