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

Unified Diff: runtime/bin/file_fuchsia.cc

Issue 2844493004: Allow fuchsia to open non-regular files. (Closed)
Patch Set: Created 3 years, 8 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/file_fuchsia.cc
diff --git a/runtime/bin/file_fuchsia.cc b/runtime/bin/file_fuchsia.cc
index 682428268ecb6203106c41041b1f1e38f24d02b2..928b76dc59611be59da2b1c8fd7b7e6ae41f604b 100644
--- a/runtime/bin/file_fuchsia.cc
+++ b/runtime/bin/file_fuchsia.cc
@@ -193,14 +193,6 @@ File* File::FileOpenW(const wchar_t* system_name, FileOpenMode mode) {
File* File::Open(const char* name, FileOpenMode mode) {
- // Report errors for non-regular files.
- struct stat st;
- if (NO_RETRY_EXPECTED(stat(name, &st)) == 0) {
zra 2017/04/26 17:34:13 Could you explain why this is needed? This change
- if (!S_ISREG(st.st_mode)) {
- errno = (S_ISDIR(st.st_mode)) ? EISDIR : ENOENT;
- return NULL;
- }
- }
int flags = O_RDONLY;
if ((mode & kWrite) != 0) {
ASSERT((mode & kWriteOnly) == 0);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698