(void)instate; /* no use for this yet */
if(imapcode != 'O') {
- failf(data, "STARTTLS denied. %c", imapcode);
- result = CURLE_USE_SSL_FAILED;
+ if(data->set.use_ssl != CURLUSESSL_TRY) {
+ failf(data, "STARTTLS denied. %c", imapcode);
+ result = CURLE_USE_SSL_FAILED;
+ }
+ else
+ result = imap_state_login(conn);
}
else {
if(data->state.used_interface == Curl_if_multi) {
(void)instate; /* no use for this yet */
if(pop3code != 'O') {
- failf(data, "STARTTLS denied. %c", pop3code);
- result = CURLE_USE_SSL_FAILED;
- state(conn, POP3_STOP);
+ if(data->set.use_ssl != CURLUSESSL_TRY) {
+ failf(data, "STARTTLS denied. %c", pop3code);
+ result = CURLE_USE_SSL_FAILED;
+ state(conn, POP3_STOP);
+ }
+ else
+ result = pop3_state_user(conn);
}
else {
/* Curl_ssl_connect is BLOCKING */