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

Unified Diff: native_client_sdk/src/libraries/nacl_io/node.cc

Issue 547713002: [NaCl SDK] nacl_io: Always create directory node in http filesystem root. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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
Index: native_client_sdk/src/libraries/nacl_io/node.cc
diff --git a/native_client_sdk/src/libraries/nacl_io/node.cc b/native_client_sdk/src/libraries/nacl_io/node.cc
index 373f96656ec3e7bda14fb21ea56623c6099ecc67..a09770898c30ae8b835ab0d5c81230a86e2ff227 100644
--- a/native_client_sdk/src/libraries/nacl_io/node.cc
+++ b/native_client_sdk/src/libraries/nacl_io/node.cc
@@ -199,6 +199,12 @@ void Node::SetType(int type) {
stat_.st_mode |= type;
}
+void Node::SetMode(int mode) {
+ assert((mode & S_IFMT) == 0);
+ stat_.st_mode &= S_IFMT;
+ stat_.st_mode |= mode;
+}
+
bool Node::IsaDir() {
return GetType() == S_IFDIR;
}
« no previous file with comments | « native_client_sdk/src/libraries/nacl_io/node.h ('k') | native_client_sdk/src/tests/nacl_io_test/http_fs_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698