From: Daniel Stenberg Date: Fri, 23 Mar 2001 07:52:45 +0000 (+0000) Subject: now always stops reading a HEAD reply after all the headers have been returned X-Git-Tag: curl-7_7_1~29 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=02f6894af5ac2bdd2e8468bc48011cfdae72ea14;p=thirdparty%2Fcurl.git now always stops reading a HEAD reply after all the headers have been returned RFC 2616, section 9.4 says: "The HEAD method is identical to GET except that the server MUST NOT return a message-body in the response." --- diff --git a/lib/transfer.c b/lib/transfer.c index 13f292d135..54fbab1823 100644 --- a/lib/transfer.c +++ b/lib/transfer.c @@ -356,11 +356,10 @@ Transfer(struct connectdata *c_conn) /* * end-of-headers. * - * If we requested a "no body" and this isn't a "close" - * connection, this is a good time to get out and return - * home. + * If we requested a "no body", this is a good time to get + * out and return home. */ - if(!conn->bits.close && data->bits.no_body) + if(data->bits.no_body) return CURLE_OK; break; /* exit header line loop */ }