]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
pop3: revert connection ssl check
authorStefan Eissing <stefan@eissing.org>
Tue, 4 Feb 2025 20:53:55 +0000 (21:53 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Tue, 4 Feb 2025 22:00:58 +0000 (23:00 +0100)
As reported in #16166, the STLS hangs with the check for SSL connection
filters, but is working with the old protocol handler way. Revert the
change, although it is unclear why it was no good here.

Fixes #16166
Reported-by: ralfjunker on github
Closes #16172

lib/pop3.c

index 8750374d0d9d6f0ec29478e874db8464cb734d88..86e9eca85580d870df653093eb32479a20e4f1bc 100644 (file)
@@ -1112,7 +1112,10 @@ static CURLcode pop3_multi_statemach(struct Curl_easy *data, bool *done)
   struct connectdata *conn = data->conn;
   struct pop3_conn *pop3c = &conn->proto.pop3c;
 
-  if(Curl_conn_is_ssl(conn, FIRSTSOCKET) && !pop3c->ssldone) {
+  /* Issue #16166, STLS seems to stall and time out. Revert to previous
+   * check, but it remains to find out why this is wrong. */
+  /* if(Curl_conn_is_ssl(conn, FIRSTSOCKET) && !pop3c->ssldone) { */
+  if((conn->handler->flags & PROTOPT_SSL) && !pop3c->ssldone) {
     bool ssldone = FALSE;
     result = Curl_conn_connect(data, FIRSTSOCKET, FALSE, &ssldone);
     pop3c->ssldone = ssldone;