From 8eb8a0a8e4ee854f063d589fc97bfbf89836a5dd Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Mon, 12 Mar 2001 09:44:57 +0000 Subject: bugfix: don't use the connectindex if it is -1 --- lib/url.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/url.c') diff --git a/lib/url.c b/lib/url.c index 44e2328fb..c6e19df02 100644 --- a/lib/url.c +++ b/lib/url.c @@ -1814,7 +1814,8 @@ CURLcode Curl_connect(struct UrlData *data, int index; index = conn->connectindex; /* get the index */ Curl_disconnect(conn); /* close the connection */ - data->connects[index]=NULL; /* clear the pointer */ + if(-1 != index) + data->connects[index]=NULL; /* clear the pointer */ } } return code; -- cgit v1.2.3