Loading lib/pop3.c +9 −9 Original line number Diff line number Diff line Loading @@ -434,7 +434,7 @@ static CURLcode pop3_state_upgrade_tls(struct connectdata *conn) static CURLcode pop3_state_user(struct connectdata *conn) { CURLcode result = CURLE_OK; struct FTP *pop3 = conn->data->state.proto.pop3; struct POP3 *pop3 = conn->data->state.proto.pop3; /* Check we have a username and password to authenticate with and end the connect phase if we don't */ Loading Loading @@ -1011,7 +1011,7 @@ static CURLcode pop3_state_user_resp(struct connectdata *conn, int pop3code, { CURLcode result = CURLE_OK; struct SessionHandle *data = conn->data; struct FTP *pop3 = data->state.proto.pop3; struct POP3 *pop3 = data->state.proto.pop3; (void)instate; /* no use for this yet */ Loading Loading @@ -1064,7 +1064,7 @@ static CURLcode pop3_command(struct connectdata *conn) if(pop3c->mailbox[0] != '\0') { /* Message specific LIST so skip the BODY transfer */ struct FTP *pop3 = conn->data->state.proto.pop3; struct POP3 *pop3 = conn->data->state.proto.pop3; pop3->transfer = FTPTRANSFER_INFO; } } Loading Loading @@ -1096,7 +1096,7 @@ static CURLcode pop3_state_command_resp(struct connectdata *conn, { CURLcode result = CURLE_OK; struct SessionHandle *data = conn->data; struct FTP *pop3 = data->state.proto.pop3; struct POP3 *pop3 = data->state.proto.pop3; struct pop3_conn *pop3c = &conn->proto.pop3c; struct pingpong *pp = &pop3c->pp; Loading Loading @@ -1289,10 +1289,10 @@ static CURLcode pop3_block_statemach(struct connectdata *conn) static CURLcode pop3_init(struct connectdata *conn) { struct SessionHandle *data = conn->data; struct FTP *pop3 = data->state.proto.pop3; struct POP3 *pop3 = data->state.proto.pop3; if(!pop3) { pop3 = data->state.proto.pop3 = calloc(sizeof(struct FTP), 1); pop3 = data->state.proto.pop3 = calloc(sizeof(struct POP3), 1); if(!pop3) return CURLE_OUT_OF_MEMORY; } Loading Loading @@ -1379,7 +1379,7 @@ static CURLcode pop3_done(struct connectdata *conn, CURLcode status, { CURLcode result = CURLE_OK; struct SessionHandle *data = conn->data; struct FTP *pop3 = data->state.proto.pop3; struct POP3 *pop3 = data->state.proto.pop3; struct pop3_conn *pop3c = &conn->proto.pop3c; (void)premature; Loading Loading @@ -1424,7 +1424,7 @@ static CURLcode pop3_perform(struct connectdata *conn, bool *connected, if(conn->data->set.opt_no_body) { /* Requested no body means no transfer */ struct FTP *pop3 = conn->data->state.proto.pop3; struct POP3 *pop3 = conn->data->state.proto.pop3; pop3->transfer = FTPTRANSFER_INFO; } Loading Loading @@ -1577,7 +1577,7 @@ static CURLcode pop3_parse_custom_request(struct connectdata *conn) /* Call this when the DO phase has completed */ static CURLcode pop3_dophase_done(struct connectdata *conn, bool connected) { struct FTP *pop3 = conn->data->state.proto.pop3; struct POP3 *pop3 = conn->data->state.proto.pop3; (void)connected; Loading lib/pop3.h +13 −0 Original line number Diff line number Diff line Loading @@ -22,6 +22,8 @@ * ***************************************************************************/ #include "pingpong.h" /**************************************************************************** * POP3 unique setup ***************************************************************************/ Loading Loading @@ -50,6 +52,17 @@ typedef enum { POP3_LAST /* never used */ } pop3state; /* This POP3 struct is used in the SessionHandle. All POP3 data that is connection-oriented must be in pop3_conn to properly deal with the fact that perhaps the SessionHandle is changed between the times the connection is used. */ struct POP3 { curl_off_t *bytecountp; char *user; /* User name string */ char *passwd; /* Password string */ curl_ftptransfer transfer; }; /* pop3_conn is used for struct connection-oriented data in the connectdata struct */ struct pop3_conn { Loading lib/urldata.h +1 −1 Original line number Diff line number Diff line Loading @@ -1293,7 +1293,7 @@ struct UrlState { void *generic; struct SSHPROTO *ssh; struct IMAP *imap; struct FTP *pop3; struct POP3 *pop3; struct FTP *smtp; } proto; /* current user of this SessionHandle instance, or NULL */ Loading Loading
lib/pop3.c +9 −9 Original line number Diff line number Diff line Loading @@ -434,7 +434,7 @@ static CURLcode pop3_state_upgrade_tls(struct connectdata *conn) static CURLcode pop3_state_user(struct connectdata *conn) { CURLcode result = CURLE_OK; struct FTP *pop3 = conn->data->state.proto.pop3; struct POP3 *pop3 = conn->data->state.proto.pop3; /* Check we have a username and password to authenticate with and end the connect phase if we don't */ Loading Loading @@ -1011,7 +1011,7 @@ static CURLcode pop3_state_user_resp(struct connectdata *conn, int pop3code, { CURLcode result = CURLE_OK; struct SessionHandle *data = conn->data; struct FTP *pop3 = data->state.proto.pop3; struct POP3 *pop3 = data->state.proto.pop3; (void)instate; /* no use for this yet */ Loading Loading @@ -1064,7 +1064,7 @@ static CURLcode pop3_command(struct connectdata *conn) if(pop3c->mailbox[0] != '\0') { /* Message specific LIST so skip the BODY transfer */ struct FTP *pop3 = conn->data->state.proto.pop3; struct POP3 *pop3 = conn->data->state.proto.pop3; pop3->transfer = FTPTRANSFER_INFO; } } Loading Loading @@ -1096,7 +1096,7 @@ static CURLcode pop3_state_command_resp(struct connectdata *conn, { CURLcode result = CURLE_OK; struct SessionHandle *data = conn->data; struct FTP *pop3 = data->state.proto.pop3; struct POP3 *pop3 = data->state.proto.pop3; struct pop3_conn *pop3c = &conn->proto.pop3c; struct pingpong *pp = &pop3c->pp; Loading Loading @@ -1289,10 +1289,10 @@ static CURLcode pop3_block_statemach(struct connectdata *conn) static CURLcode pop3_init(struct connectdata *conn) { struct SessionHandle *data = conn->data; struct FTP *pop3 = data->state.proto.pop3; struct POP3 *pop3 = data->state.proto.pop3; if(!pop3) { pop3 = data->state.proto.pop3 = calloc(sizeof(struct FTP), 1); pop3 = data->state.proto.pop3 = calloc(sizeof(struct POP3), 1); if(!pop3) return CURLE_OUT_OF_MEMORY; } Loading Loading @@ -1379,7 +1379,7 @@ static CURLcode pop3_done(struct connectdata *conn, CURLcode status, { CURLcode result = CURLE_OK; struct SessionHandle *data = conn->data; struct FTP *pop3 = data->state.proto.pop3; struct POP3 *pop3 = data->state.proto.pop3; struct pop3_conn *pop3c = &conn->proto.pop3c; (void)premature; Loading Loading @@ -1424,7 +1424,7 @@ static CURLcode pop3_perform(struct connectdata *conn, bool *connected, if(conn->data->set.opt_no_body) { /* Requested no body means no transfer */ struct FTP *pop3 = conn->data->state.proto.pop3; struct POP3 *pop3 = conn->data->state.proto.pop3; pop3->transfer = FTPTRANSFER_INFO; } Loading Loading @@ -1577,7 +1577,7 @@ static CURLcode pop3_parse_custom_request(struct connectdata *conn) /* Call this when the DO phase has completed */ static CURLcode pop3_dophase_done(struct connectdata *conn, bool connected) { struct FTP *pop3 = conn->data->state.proto.pop3; struct POP3 *pop3 = conn->data->state.proto.pop3; (void)connected; Loading
lib/pop3.h +13 −0 Original line number Diff line number Diff line Loading @@ -22,6 +22,8 @@ * ***************************************************************************/ #include "pingpong.h" /**************************************************************************** * POP3 unique setup ***************************************************************************/ Loading Loading @@ -50,6 +52,17 @@ typedef enum { POP3_LAST /* never used */ } pop3state; /* This POP3 struct is used in the SessionHandle. All POP3 data that is connection-oriented must be in pop3_conn to properly deal with the fact that perhaps the SessionHandle is changed between the times the connection is used. */ struct POP3 { curl_off_t *bytecountp; char *user; /* User name string */ char *passwd; /* Password string */ curl_ftptransfer transfer; }; /* pop3_conn is used for struct connection-oriented data in the connectdata struct */ struct pop3_conn { Loading
lib/urldata.h +1 −1 Original line number Diff line number Diff line Loading @@ -1293,7 +1293,7 @@ struct UrlState { void *generic; struct SSHPROTO *ssh; struct IMAP *imap; struct FTP *pop3; struct POP3 *pop3; struct FTP *smtp; } proto; /* current user of this SessionHandle instance, or NULL */ Loading