Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(676)

Unified Diff: net/http/http_basic_stream.cc

Issue 403393003: HTTP retry support. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/http/http_basic_stream.cc
diff --git a/net/http/http_basic_stream.cc b/net/http/http_basic_stream.cc
index 0d14e0f9a0eac6683aa6ff8a411cffe4fb796ca1..5b32a2bb9de05ad2c4b7227f5b9fdae4eebe4ba1 100644
--- a/net/http/http_basic_stream.cc
+++ b/net/http/http_basic_stream.cc
@@ -87,6 +87,12 @@ int64 HttpBasicStream::GetTotalReceivedBytes() const {
return 0;
}
+int64 HttpBasicStream::GetReceivedBodyLength() const {
+ if (parser())
+ return parser()->GetReceivedBodyLength();
+ return 0;
+}
+
bool HttpBasicStream::GetLoadTimingInfo(
LoadTimingInfo* load_timing_info) const {
return state_.connection()->GetLoadTimingInfo(IsConnectionReused(),
@@ -114,4 +120,13 @@ void HttpBasicStream::SetPriority(RequestPriority priority) {
// TODO(akalin): Plumb this through to |connection_|.
}
+void HttpBasicStream::SetRestartInfo(
+ int64 read_offset, const void* hash, size_t hash_length) {
+ parser()->SetRestartInfo(read_offset, hash, hash_length);
+}
+
+void HttpBasicStream::GetHash(void* output, size_t len) {
+ parser()->GetHash(output, len);
+}
+
} // namespace net

Powered by Google App Engine
This is Rietveld 408576698