You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using libcURL, and setting the request method to HEAD, if the server responds with a header which gives certain indications that there may be a body, the request hangs for 5 minutes while waiting for the body before timing out.
I did this
I set the CURLOPT_NOBODY option as a workaround.
I expected the following
Because by definition a HEAD request can contain no body, it seems that the CURLOPT_NOBODY would not need to be set when using the HEAD method. The curl library should know not to expect a body, simply by setting the HEAD request method. As I read specs on using the HEAD method, it is intended to return the same header information as if a body had been requested, but simply return ONLY the header with no body.
curl/libcurl version
7.40.0 and 7.55.1
[curl -V output]
operating system
Windows Vista (32-bit), Windows 7 (64-bit), Windows 10 (64-bit)
The text was updated successfully, but these errors were encountered:
When you change the request method by setting CURLOPT_CUSTOMREQUEST to something, you don't actually change how libcurl behaves or acts in regards to the particular request method, it will only change the actual string sent in the request.
CURLOPT_NOBODY is not a work-around, it is how you send a HTTP request that won't wait around to read the body.
When using libcURL, and setting the request method to HEAD, if the server responds with a header which gives certain indications that there may be a body, the request hangs for 5 minutes while waiting for the body before timing out.
I did this
I set the CURLOPT_NOBODY option as a workaround.
I expected the following
Because by definition a HEAD request can contain no body, it seems that the CURLOPT_NOBODY would not need to be set when using the HEAD method. The curl library should know not to expect a body, simply by setting the HEAD request method. As I read specs on using the HEAD method, it is intended to return the same header information as if a body had been requested, but simply return ONLY the header with no body.
curl/libcurl version
7.40.0 and 7.55.1
[curl -V output]
operating system
Windows Vista (32-bit), Windows 7 (64-bit), Windows 10 (64-bit)
The text was updated successfully, but these errors were encountered: