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

Unified Diff: mojo/public/platform/nacl/libmojo.cc

Issue 2106433002: Add thunks for wait set operations, together with public tests. (Closed) Base URL: https://github.com/domokit/mojo.git@work791_wait_set_6-x-work790_wait_set_5.4
Patch Set: doh Created 4 years, 6 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 | « mojo/public/c/system/wait_set.h ('k') | mojo/public/platform/nacl/mojo_irt.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/platform/nacl/libmojo.cc
diff --git a/mojo/public/platform/nacl/libmojo.cc b/mojo/public/platform/nacl/libmojo.cc
index 81fb436175564bf89048aaf8d9c73204fd0d2e63..7dbdff89bba2eb57991141897e62bdcc2c33b3f5 100644
--- a/mojo/public/platform/nacl/libmojo.cc
+++ b/mojo/public/platform/nacl/libmojo.cc
@@ -14,6 +14,7 @@
#include "mojo/public/c/system/result.h"
#include "mojo/public/c/system/time.h"
#include "mojo/public/c/system/wait.h"
+#include "mojo/public/c/system/wait_set.h"
#include "mojo/public/platform/nacl/mojo_irt.h"
#include "native_client/src/untrusted/irt/irt.h"
@@ -312,3 +313,41 @@ MojoResult MojoUnmapBuffer(void* buffer) {
return irt_mojo->MojoUnmapBuffer(buffer);
}
+MojoResult MojoCreateWaitSet(const struct MojoCreateWaitSetOptions* options,
+ MojoHandle* handle) {
+ struct nacl_irt_mojo* irt_mojo = get_irt_mojo();
+ if (!irt_mojo)
+ abort();
+ return irt_mojo->MojoCreateWaitSet(options, handle);
+}
+
+MojoResult MojoWaitSetAdd(MojoHandle wait_set_handle,
+ MojoHandle handle,
+ MojoHandleSignals signals,
+ uint64_t cookie,
+ const struct MojoWaitSetAddOptions* options) {
+ struct nacl_irt_mojo* irt_mojo = get_irt_mojo();
+ if (!irt_mojo)
+ abort();
+ return irt_mojo->MojoWaitSetAdd(wait_set_handle, handle, signals, cookie,
+ options);
+}
+
+MojoResult MojoWaitSetRemove(MojoHandle wait_set_handle, uint64_t cookie) {
+ struct nacl_irt_mojo* irt_mojo = get_irt_mojo();
+ if (!irt_mojo)
+ abort();
+ return irt_mojo->MojoWaitSetRemove(wait_set_handle, cookie);
+}
+
+MojoResult MojoWaitSetWait(MojoHandle wait_set_handle,
+ MojoDeadline deadline,
+ uint32_t* num_results,
+ struct MojoWaitSetResult* results,
+ uint32_t* max_results) {
+ struct nacl_irt_mojo* irt_mojo = get_irt_mojo();
+ if (!irt_mojo)
+ abort();
+ return irt_mojo->MojoWaitSetWait(wait_set_handle, deadline, num_results,
+ results, max_results);
+}
« no previous file with comments | « mojo/public/c/system/wait_set.h ('k') | mojo/public/platform/nacl/mojo_irt.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698