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

Unified Diff: runtime/bin/file_linux.cc

Issue 22381002: Fixes to get Dart VM compiling on Ubuntu 13.04, Debian Wheezy. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Alternative type-punning fix Created 7 years, 4 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 b45ce046a79597b8ea0087297ab49b0b394377c0..8d5171a2e6612bb5ee3152a98d42d75a15c85755 100644
--- a/runtime/bin/file_linux.cc
+++ b/runtime/bin/file_linux.cc
@@ -47,10 +47,7 @@ void File::Close() {
ASSERT(handle_->fd() >= 0);
int err = TEMP_FAILURE_RETRY(close(handle_->fd()));
if (err != 0) {
- const int kBufferSize = 1024;
- char error_message[kBufferSize];
- strerror_r(errno, error_message, kBufferSize);
- Log::PrintErr("%s\n", error_message);
+ Log::PrintErr("%s\n", strerror(errno));
Ivan Posva 2013/08/07 18:33:44 strerror is not multithread safe and you should be
}
handle_->set_fd(kClosedFd);
}

Powered by Google App Engine
This is Rietveld 408576698