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

Unified Diff: runtime/bin/file_linux.cc

Issue 1466523002: Landing patch set 7 from https://codereview.chromium.org/1450113003/ (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 1 month 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 | « runtime/bin/file_android.cc ('k') | runtime/bin/file_macos.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/file_linux.cc
diff --git a/runtime/bin/file_linux.cc b/runtime/bin/file_linux.cc
index ff801adf8fe7efe5e4443ea0868e38bb69d8bea1..d289c213bd8467da7730e185c96aa02895f96347 100644
--- a/runtime/bin/file_linux.cc
+++ b/runtime/bin/file_linux.cc
@@ -15,9 +15,10 @@
#include <unistd.h> // NOLINT
#include <libgen.h> // NOLINT
-#include "platform/signal_blocker.h"
#include "bin/builtin.h"
#include "bin/log.h"
+#include "platform/signal_blocker.h"
+#include "platform/utils.h"
namespace dart {
@@ -56,7 +57,7 @@ void File::Close() {
if (err != 0) {
const int kBufferSize = 1024;
char error_buf[kBufferSize];
- Log::PrintErr("%s\n", strerror_r(errno, error_buf, kBufferSize));
+ Log::PrintErr("%s\n", Utils::StrError(errno, error_buf, kBufferSize));
}
}
handle_->set_fd(kClosedFd);
@@ -429,7 +430,7 @@ File::StdioHandleType File::GetStdioHandleType(int fd) {
const int kBufferSize = 1024;
char error_buf[kBufferSize];
FATAL2("Failed stat on file descriptor %d: %s", fd,
- strerror_r(errno, error_buf, kBufferSize));
+ Utils::StrError(errno, error_buf, kBufferSize));
}
if (S_ISCHR(buf.st_mode)) return kTerminal;
if (S_ISFIFO(buf.st_mode)) return kPipe;
« no previous file with comments | « runtime/bin/file_android.cc ('k') | runtime/bin/file_macos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698