aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2006-07-11 00:23:21 +0000
committerYang Tse <yangsita@gmail.com>2006-07-11 00:23:21 +0000
commitdcc7900e7cf7c2611ab0f30ea8be0452e30bc199 (patch)
tree22b13cb340af8ec3234b69931d94ca6a1251bf27 /lib
parent34f5e8ad0ed29d4dd7c59768339e37c9be2e533a (diff)
Socket must be set to CURL_SOCKET_BAD after closing it.
Diffstat (limited to 'lib')
-rw-r--r--lib/connect.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/connect.c b/lib/connect.c
index 1ba87099f..0b404aed7 100644
--- a/lib/connect.c
+++ b/lib/connect.c
@@ -509,6 +509,7 @@ static bool trynextip(struct connectdata *conn,
/* first close the failed socket */
sclose(conn->sock[sockindex]);
+ conn->sock[sockindex] = CURL_SOCKET_BAD;
/* try the next address */
ai = conn->ip_addr->ai_next;