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

Unified Diff: net/base/file_stream_context_posix.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/base/file_stream_context_posix.cc
diff --git a/net/base/file_stream_context_posix.cc b/net/base/file_stream_context_posix.cc
index 489216fbc24879faa5e048ad1730b2de310c1c9d..2f66b6e0314e70f67d972c6b0940ad4a7cd85e56 100644
--- a/net/base/file_stream_context_posix.cc
+++ b/net/base/file_stream_context_posix.cc
@@ -79,9 +79,8 @@ int FileStream::Context::Write(IOBuffer* in_buf,
}
FileStream::Context::IOResult FileStream::Context::SeekFileImpl(
- base::File::Whence whence,
int64 offset) {
- int64 res = file_.Seek(whence, offset);
+ int64 res = file_.Seek(base::File::FROM_BEGIN, offset);
if (res == -1)
return IOResult::FromOSError(errno);

Powered by Google App Engine
This is Rietveld 408576698