]> granicus.if.org Git - curl/commitdiff
Socket must be set to CURL_SOCKET_BAD after closing it.
authorYang Tse <yangsita@gmail.com>
Tue, 11 Jul 2006 00:23:21 +0000 (00:23 +0000)
committerYang Tse <yangsita@gmail.com>
Tue, 11 Jul 2006 00:23:21 +0000 (00:23 +0000)
lib/connect.c

index 1ba87099f6bf669c53e04114ad59716b62ae11a0..0b404aed762b5e0e6aacdc9f6f26d36d6de8c78f 100644 (file)
@@ -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;