summaryrefslogtreecommitdiff
path: root/lib/imap.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/imap.c')
-rw-r--r--lib/imap.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/lib/imap.c b/lib/imap.c
index b5236ebe4..14ea9ae57 100644
--- a/lib/imap.c
+++ b/lib/imap.c
@@ -444,10 +444,8 @@ static CURLcode imap_perform_capability(struct connectdata *conn)
*/
static CURLcode imap_perform_starttls(struct connectdata *conn)
{
- CURLcode result = CURLE_OK;
-
/* Send the STARTTLS command */
- result = imap_sendf(conn, "STARTTLS");
+ CURLcode result = imap_sendf(conn, "STARTTLS");
if(!result)
state(conn, IMAP_STARTTLS);
@@ -463,11 +461,10 @@ static CURLcode imap_perform_starttls(struct connectdata *conn)
*/
static CURLcode imap_perform_upgrade_tls(struct connectdata *conn)
{
- CURLcode result = CURLE_OK;
- struct imap_conn *imapc = &conn->proto.imapc;
-
/* Start the SSL connection */
- result = Curl_ssl_connect_nonblocking(conn, FIRSTSOCKET, &imapc->ssldone);
+ struct imap_conn *imapc = &conn->proto.imapc;
+ CURLcode result = Curl_ssl_connect_nonblocking(conn, FIRSTSOCKET,
+ &imapc->ssldone);
if(!result) {
if(imapc->state != IMAP_UPGRADETLS)
@@ -826,10 +823,8 @@ static CURLcode imap_perform_search(struct connectdata *conn)
*/
static CURLcode imap_perform_logout(struct connectdata *conn)
{
- CURLcode result = CURLE_OK;
-
/* Send the LOGOUT command */
- result = imap_sendf(conn, "LOGOUT");
+ CURLcode result = imap_sendf(conn, "LOGOUT");
if(!result)
state(conn, IMAP_LOGOUT);