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

Unified Diff: net/url_request/url_request_file_job.cc

Issue 1148383003: Only support seeking file streams from the beginning of the file. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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/url_request/url_request_file_job.cc
diff --git a/net/url_request/url_request_file_job.cc b/net/url_request/url_request_file_job.cc
index 864001e4b854efa462076fb3e56ffa10ce3934aa..5ad74021fbf17e319ccee24868820c773d0305b4 100644
--- a/net/url_request/url_request_file_job.cc
+++ b/net/url_request/url_request_file_job.cc
@@ -265,8 +265,7 @@ void URLRequestFileJob::DidOpen(int result) {
DCHECK_GE(remaining_bytes_, 0);
if (remaining_bytes_ > 0 && byte_range_.first_byte_position() != 0) {
- int rv = stream_->Seek(base::File::FROM_BEGIN,
- byte_range_.first_byte_position(),
+ int rv = stream_->Seek(byte_range_.first_byte_position(),
base::Bind(&URLRequestFileJob::DidSeek,
weak_ptr_factory_.GetWeakPtr()));
if (rv != ERR_IO_PENDING) {

Powered by Google App Engine
This is Rietveld 408576698