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

Unified Diff: net/base/file_stream_context_posix.cc

Issue 23500006: URLFetcher won't call delegate until file is closed. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: mmenke's 3rd review Created 7 years, 3 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
« no previous file with comments | « net/base/file_stream_context.cc ('k') | net/base/file_stream_context_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 1ef5be5fc16259364eedc03c63727953fc2dbe40..6e6bc6eaa698666b2245cbb32b28a91215fb3b8c 100644
--- a/net/base/file_stream_context_posix.cc
+++ b/net/base/file_stream_context_posix.cc
@@ -184,4 +184,13 @@ FileStream::Context::IOResult FileStream::Context::WriteFileImpl(
return IOResult(res, 0);
}
+FileStream::Context::IOResult FileStream::Context::CloseFileImpl() {
+ bool success = base::ClosePlatformFile(file_);
+ file_ = base::kInvalidPlatformFileValue;
+ if (!success)
+ return IOResult::FromOSError(errno);
+
+ return IOResult(OK, 0);
+}
+
} // namespace net
« no previous file with comments | « net/base/file_stream_context.cc ('k') | net/base/file_stream_context_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698