Skip to content

Terminate http request on response status code 416.

username-removed-267665 requested to merge fix-416 into master
  • libwget/http.c (wget_http_get_response_cb): Stop download on status code 416, cleanup using HTTP status defines.
  • libwget/http.h: Add HTTP status defines from Wget1.x

HTTP status response 416 Requested Range Not Satisfiable. This sometimes happens when a server responds incorrectly to a range request. There is not enough information available (Range of the request) to properly handle this case. If it were, the case that the file has already been completely downloaded could be detected and an appropriate message could be generated. I also took the liberty to port the status codes from the old wget source to libwget/http.h to make the code more readable.

Merge request reports