Commit fc48106d authored by Andreas Schwab's avatar Andreas Schwab

Fix imap-starttls-open

* lisp/net/imap.el (imap-starttls-open): Log imap process
output.  Call imap-parse-greeting.  (Bug#22500)
parent cdecbedb
......@@ -747,14 +747,19 @@ sure of changing the value of `foo'."
:capability-command "1 CAPABILITY\r\n"
:always-query-capabilities t
:end-of-command "\r\n"
:success " OK "
:success "^1 OK "
(lambda (capabilities)
(when (string-match-p "STARTTLS" capabilities)
"1 STARTTLS\r\n"))))
(done (if (and process
(memq (process-status process) '(open run)))
#'(lambda (capabilities)
(when (string-match-p "STARTTLS" capabilities)
"1 STARTTLS\r\n"))))
(when process
(imap-log buffer)
(when (memq (process-status process) '(open run))
(setq done process)
(with-current-buffer buffer
(goto-char (point-min))
(message "imap: Connecting with STARTTLS...%s" (if done "done" "failed"))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment