Commit 19d757ee by Paweł Wegner

IRequest: removed InvalidRange.

parent 0f444dc7
......@@ -60,7 +60,6 @@ struct Range {
};
const Range FullRange = {Range::Begin, Range::Full};
const Range InvalidRange = {-1ULL, 0};
/**
* Class representing pending request. When there is no reference to the
......
......@@ -128,7 +128,7 @@ std::string remove_whitespace(const std::string& str) {
Range parse_range(const std::string& r) {
std::string str = remove_whitespace(r);
size_t l = strlen("bytes=");
if (str.substr(0, l) != "bytes=") return InvalidRange;
if (str.substr(0, l) != "bytes=") return {0, 0};
std::string n1, n2;
size_t it = l;
while (it < r.length() && str[it] != '-') n1 += str[it++];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment