curl/curl-7.17.1-badsocket.patch

14 lines
569 B
Diff

diff -up curl-7.17.1/lib/ftp.c.badsocket curl-7.17.1/lib/ftp.c
--- curl-7.17.1/lib/ftp.c.badsocket 2007-10-27 00:25:19.000000000 +0200
+++ curl-7.17.1/lib/ftp.c 2008-01-08 15:09:03.000000000 +0100
@@ -3228,7 +3228,8 @@ static CURLcode Curl_ftp_done(struct con
/* Note that we keep "use" set to TRUE since that (next) connection is
still requested to use SSL */
}
- sclose(conn->sock[SECONDARYSOCKET]);
+ if(CURL_SOCKET_BAD != conn->sock[SECONDARYSOCKET])
+ sclose(conn->sock[SECONDARYSOCKET]);
conn->sock[SECONDARYSOCKET] = CURL_SOCKET_BAD;