1
0
mirror of https://github.com/moparisthebest/curl synced 2024-12-21 23:58:49 -05:00

email: Post STARTLS capability code tidy up (Part One)

Corrected the order of the CAPA / CAPABILITY state machine constants to
match the execution order.
This commit is contained in:
Steve Holme 2013-02-10 21:18:30 +00:00
parent 18d1ea4528
commit 85a2e9ec82
4 changed files with 12 additions and 12 deletions

View File

@ -433,9 +433,9 @@ static void state(struct connectdata *conn, imapstate newstate)
static const char * const names[]={ static const char * const names[]={
"STOP", "STOP",
"SERVERGREET", "SERVERGREET",
"CAPABILITY",
"STARTTLS", "STARTTLS",
"UPGRADETLS", "UPGRADETLS",
"CAPABILITY",
"AUTHENTICATE_PLAIN", "AUTHENTICATE_PLAIN",
"AUTHENTICATE_LOGIN", "AUTHENTICATE_LOGIN",
"AUTHENTICATE_LOGIN_PASSWD", "AUTHENTICATE_LOGIN_PASSWD",
@ -1265,14 +1265,14 @@ static CURLcode imap_statemach_act(struct connectdata *conn)
result = imap_state_servergreet_resp(conn, imapcode, imapc->state); result = imap_state_servergreet_resp(conn, imapcode, imapc->state);
break; break;
case IMAP_STARTTLS:
result = imap_state_starttls_resp(conn, imapcode, imapc->state);
break;
case IMAP_CAPABILITY: case IMAP_CAPABILITY:
result = imap_state_capability_resp(conn, imapcode, imapc->state); result = imap_state_capability_resp(conn, imapcode, imapc->state);
break; break;
case IMAP_STARTTLS:
result = imap_state_starttls_resp(conn, imapcode, imapc->state);
break;
case IMAP_AUTHENTICATE_PLAIN: case IMAP_AUTHENTICATE_PLAIN:
result = imap_state_auth_plain_resp(conn, imapcode, imapc->state); result = imap_state_auth_plain_resp(conn, imapcode, imapc->state);
break; break;

View File

@ -31,10 +31,10 @@ typedef enum {
IMAP_STOP, /* do nothing state, stops the state machine */ IMAP_STOP, /* do nothing state, stops the state machine */
IMAP_SERVERGREET, /* waiting for the initial greeting immediately after IMAP_SERVERGREET, /* waiting for the initial greeting immediately after
a connect */ a connect */
IMAP_CAPABILITY,
IMAP_STARTTLS, IMAP_STARTTLS,
IMAP_UPGRADETLS, /* asynchronously upgrade the connection to SSL/TLS IMAP_UPGRADETLS, /* asynchronously upgrade the connection to SSL/TLS
(multi mode only) */ (multi mode only) */
IMAP_CAPABILITY,
IMAP_AUTHENTICATE_PLAIN, IMAP_AUTHENTICATE_PLAIN,
IMAP_AUTHENTICATE_LOGIN, IMAP_AUTHENTICATE_LOGIN,
IMAP_AUTHENTICATE_LOGIN_PASSWD, IMAP_AUTHENTICATE_LOGIN_PASSWD,

View File

@ -345,9 +345,9 @@ static void state(struct connectdata *conn, pop3state newstate)
static const char * const names[] = { static const char * const names[] = {
"STOP", "STOP",
"SERVERGREET", "SERVERGREET",
"CAPA",
"STARTTLS", "STARTTLS",
"UPGRADETLS", "UPGRADETLS",
"CAPA",
"AUTH_PLAIN", "AUTH_PLAIN",
"AUTH_LOGIN", "AUTH_LOGIN",
"AUTH_LOGIN_PASSWD", "AUTH_LOGIN_PASSWD",
@ -1185,14 +1185,14 @@ static CURLcode pop3_statemach_act(struct connectdata *conn)
result = pop3_state_servergreet_resp(conn, pop3code, pop3c->state); result = pop3_state_servergreet_resp(conn, pop3code, pop3c->state);
break; break;
case POP3_STARTTLS:
result = pop3_state_starttls_resp(conn, pop3code, pop3c->state);
break;
case POP3_CAPA: case POP3_CAPA:
result = pop3_state_capa_resp(conn, pop3code, pop3c->state); result = pop3_state_capa_resp(conn, pop3code, pop3c->state);
break; break;
case POP3_STARTTLS:
result = pop3_state_starttls_resp(conn, pop3code, pop3c->state);
break;
case POP3_AUTH_PLAIN: case POP3_AUTH_PLAIN:
result = pop3_state_auth_plain_resp(conn, pop3code, pop3c->state); result = pop3_state_auth_plain_resp(conn, pop3code, pop3c->state);
break; break;

View File

@ -29,10 +29,10 @@ typedef enum {
POP3_STOP, /* do nothing state, stops the state machine */ POP3_STOP, /* do nothing state, stops the state machine */
POP3_SERVERGREET, /* waiting for the initial greeting immediately after POP3_SERVERGREET, /* waiting for the initial greeting immediately after
a connect */ a connect */
POP3_CAPA,
POP3_STARTTLS, POP3_STARTTLS,
POP3_UPGRADETLS, /* asynchronously upgrade the connection to SSL/TLS POP3_UPGRADETLS, /* asynchronously upgrade the connection to SSL/TLS
(multi mode only) */ (multi mode only) */
POP3_CAPA,
POP3_AUTH_PLAIN, POP3_AUTH_PLAIN,
POP3_AUTH_LOGIN, POP3_AUTH_LOGIN,
POP3_AUTH_LOGIN_PASSWD, POP3_AUTH_LOGIN_PASSWD,