summaryrefslogtreecommitdiff
path: root/native_client_sdk
diff options
context:
space:
mode:
authorBen Murdoch <benm@google.com>2013-07-31 11:42:55 +0100
committerBen Murdoch <benm@google.com>2013-07-31 11:42:55 +0100
commitfb250657ef40d7500f20882d5c9909c1013367d3 (patch)
treee7885d8f55b77d8ec4430fa4ec78add75c7270d8 /native_client_sdk
parent8b098b9dd9d1242c3db3032622b35d8469d47ac4 (diff)
downloadchromium_org-fb250657ef40d7500f20882d5c9909c1013367d3.tar.gz
Merge from Chromium at DEPS revision r214456
This commit was generated by merge_to_master.py. Change-Id: If3f38c7966c2034e96c669968f72ea1e57f41964
Diffstat (limited to 'native_client_sdk')
-rw-r--r--native_client_sdk/src/libraries/nacl_io/mount_node.cc7
-rw-r--r--native_client_sdk/src/libraries/nacl_io/mount_node.h6
2 files changed, 12 insertions, 1 deletions
diff --git a/native_client_sdk/src/libraries/nacl_io/mount_node.cc b/native_client_sdk/src/libraries/nacl_io/mount_node.cc
index d1d034d07f..e8178cc1c0 100644
--- a/native_client_sdk/src/libraries/nacl_io/mount_node.cc
+++ b/native_client_sdk/src/libraries/nacl_io/mount_node.cc
@@ -48,6 +48,13 @@ void MountNode::Destroy() {
}
}
+// Declared in EventEmitter, default to regular files which always return
+// a ready of TRUE.
+uint32_t MountNode::GetEventStatus() {
+ return KE_READ_READY | KE_WRITE_READY | KE_SHUTDOWN;
+}
+
+
Error MountNode::FSync() { return 0; }
Error MountNode::FTruncate(off_t length) { return EINVAL; }
diff --git a/native_client_sdk/src/libraries/nacl_io/mount_node.h b/native_client_sdk/src/libraries/nacl_io/mount_node.h
index 30832dd149..bf9534e558 100644
--- a/native_client_sdk/src/libraries/nacl_io/mount_node.h
+++ b/native_client_sdk/src/libraries/nacl_io/mount_node.h
@@ -8,6 +8,7 @@
#include <string>
#include "nacl_io/error.h"
+#include "nacl_io/event_listener.h"
#include "nacl_io/osdirent.h"
#include "nacl_io/osstat.h"
@@ -24,7 +25,7 @@ typedef sdk_util::ScopedRef<MountNode> ScopedMountNode;
// NOTE: The KernelProxy is the only class that should be setting errno. All
// other classes should return Error (as defined by nacl_io/error.h).
-class MountNode : public sdk_util::RefObject {
+class MountNode : public EventListener {
protected:
explicit MountNode(Mount* mount);
virtual ~MountNode();
@@ -35,6 +36,9 @@ class MountNode : public sdk_util::RefObject {
virtual void Destroy();
public:
+ // Declared in EventEmitter. defaults to signalled.
+ virtual uint32_t GetEventStatus();
+
// Normal OS operations on a node (file), can be called by the kernel
// directly so it must lock and unlock appropriately. These functions
// must not be called by the mount.