瀏覽代碼

don't use STARTTLS for PREAUTH connections. uw-imap doesn't seem to like
it, and it does not make too much sense anyway - i think - state converse
opinions now.

Oswald Buddenhagen 21 年之前
父節點
當前提交
1eb6e35c80
共有 1 個文件被更改,包括 4 次插入3 次删除
  1. 4 3
      src/imap.c

+ 4 - 3
src/imap.c

@@ -742,6 +742,9 @@ imap_connect (config_t * cfg)
       if (imap_exec (imap, "CAPABILITY"))
       if (imap_exec (imap, "CAPABILITY"))
 	goto bail;
 	goto bail;
 
 
+    if (!preauth)
+    {
+
 #if HAVE_LIBSSL
 #if HAVE_LIBSSL
       if (!cfg->use_imaps)
       if (!cfg->use_imaps)
       {
       {
@@ -780,8 +783,6 @@ imap_connect (config_t * cfg)
       }
       }
 #endif
 #endif
 
 
-      if (!preauth)
-      {
 	info ("Logging in...\n");
 	info ("Logging in...\n");
 
 
 	if (!cfg->pass)
 	if (!cfg->pass)
@@ -842,7 +843,7 @@ imap_connect (config_t * cfg)
 	    goto bail;
 	    goto bail;
 	  }
 	  }
 	}
 	}
-      }
+    } /* !preauth */
 
 
       /* get NAMESPACE info */
       /* get NAMESPACE info */
       if (cfg->use_namespace && imap->have_namespace)
       if (cfg->use_namespace && imap->have_namespace)