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

Unified Diff: runtime/bin/file_linux.cc

Issue 9839053: Add error handling to random access file (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 9 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: runtime/bin/file_linux.cc
diff --git a/runtime/bin/file_linux.cc b/runtime/bin/file_linux.cc
index 05ac74dc0a903b11646cd19555df298fc24ffbc7..f04234fbea7a6ef9e3743ebf2324052456605c62 100644
--- a/runtime/bin/file_linux.cc
+++ b/runtime/bin/file_linux.cc
@@ -85,9 +85,9 @@ bool File::Truncate(int64_t length) {
}
-void File::Flush() {
+bool File::Flush() {
ASSERT(handle_->fd() >= 0);
- TEMP_FAILURE_RETRY(fsync(handle_->fd()));
+ return TEMP_FAILURE_RETRY(fsync(handle_->fd()) != -1);
}

Powered by Google App Engine
This is Rietveld 408576698