summaryrefslogtreecommitdiff
path: root/src/HttpRequest.h
diff options
context:
space:
mode:
authorTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2013-02-23 15:37:35 +0900
committerTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2013-02-23 15:37:35 +0900
commitb782a56b1c178795fda4ca7ed2ee4d9621927aab (patch)
tree20cc1144d71814a2ed02be606696c72689db2f51 /src/HttpRequest.h
parent73f4db883cde5eee2f81e77c9e37f1915905139b (diff)
Show correct end byte in error message when HTTP response range is not ok
Previously, unless HTTP pipelining is enabled, end byte in that message is always 0. With this change, it shows correct end byte sent to the HTTP server.
Diffstat (limited to 'src/HttpRequest.h')
-rw-r--r--src/HttpRequest.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/HttpRequest.h b/src/HttpRequest.h
index 2d355a64..963dc6fc 100644
--- a/src/HttpRequest.h
+++ b/src/HttpRequest.h
@@ -88,6 +88,13 @@ private:
bool acceptGzip_;
+ // Historically, aria2 did not specify end byte marker unless http
+ // pipelining is enabled. Sometimes end byte is known because the
+ // segment/piece ahead of this request was already acquired. In this
+ // case, specifying end byte enables to reuse connection. To achieve
+ // this, if endOffsetOverride_ is more than 0, its value - 1 is used
+ // as an end byte. Please note that FTP protocol cannot specify end
+ // bytes and it is also true if it is used via HTTP proxy.
int64_t endOffsetOverride_;
std::string ifModSinceHeader_;