diff options
author | Steve Holme <steve_holme@hotmail.com> | 2014-10-30 23:14:45 +0000 |
---|---|---|
committer | Steve Holme <steve_holme@hotmail.com> | 2014-10-30 23:14:45 +0000 |
commit | befbc8f56b2d57b661498e936790493e0c4909f4 (patch) | |
tree | c83b576138566ed871bfc9236e4e0968b661f4a7 /lib/connect.c | |
parent | a9db36d1fde1978f74f4f42229498cce87c16de7 (diff) |
code cleanup: Use 'CURLcode result'
Diffstat (limited to 'lib/connect.c')
-rw-r--r-- | lib/connect.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/connect.c b/lib/connect.c index a8fe83042..5d522b381 100644 --- a/lib/connect.c +++ b/lib/connect.c @@ -541,7 +541,7 @@ static CURLcode trynextip(struct connectdata *conn, int sockindex, int tempindex) { - CURLcode rc = CURLE_COULDNT_CONNECT; + CURLcode result = CURLE_COULDNT_CONNECT; /* First clean up after the failed socket. Don't close it yet to ensure that the next IP's socket gets a different @@ -575,11 +575,12 @@ static CURLcode trynextip(struct connectdata *conn, ai = ai->ai_next; if(ai) { - rc = singleipconnect(conn, ai, &conn->tempsock[tempindex]); - if(rc == CURLE_COULDNT_CONNECT) { + result = singleipconnect(conn, ai, &conn->tempsock[tempindex]); + if(result == CURLE_COULDNT_CONNECT) { ai = ai->ai_next; continue; } + conn->tempaddr[tempindex] = ai; } break; @@ -589,7 +590,7 @@ static CURLcode trynextip(struct connectdata *conn, if(fd_to_close != CURL_SOCKET_BAD) Curl_closesocket(conn, fd_to_close); - return rc; + return result; } /* Copies connection info into the session handle to make it available |