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

Unified Diff: mojo/edk/embedder/platform_channel_pair_posix.cc

Issue 2071143003: Various changes to make Mojo work under NaCl non-sfi. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase and comment 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 | « ipc/mojo/ipc_mojo_bootstrap.cc ('k') | mojo/edk/embedder/platform_channel_utils_posix.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/embedder/platform_channel_pair_posix.cc
diff --git a/mojo/edk/embedder/platform_channel_pair_posix.cc b/mojo/edk/embedder/platform_channel_pair_posix.cc
index 4dcf48bd71bfe417588e9ba2d0dfd7b1bb67d65f..55f3ae24ab1b297910bbbfb5536f6b0b8089a961 100644
--- a/mojo/edk/embedder/platform_channel_pair_posix.cc
+++ b/mojo/edk/embedder/platform_channel_pair_posix.cc
@@ -20,7 +20,7 @@
#include "build/build_config.h"
#include "mojo/edk/embedder/platform_handle.h"
-#if !defined(OS_NACL) || defined(OS_NACL_NONSFI)
+#if !defined(OS_NACL_SFI)
#include <sys/socket.h>
#else
#include "native_client/src/public/imc_syscalls.h"
@@ -52,7 +52,7 @@ PlatformChannelPair::PlatformChannelPair(bool client_is_blocking) {
int fds[2];
// TODO(vtl): Maybe fail gracefully if |socketpair()| fails.
-#if defined(OS_NACL) && !defined(OS_NACL_NONSFI)
+#if defined(OS_NACL_SFI)
PCHECK(imc_socketpair(fds) == 0);
#else
PCHECK(socketpair(AF_UNIX, SOCK_STREAM, 0, fds) == 0);
@@ -72,7 +72,7 @@ PlatformChannelPair::PlatformChannelPair(bool client_is_blocking) {
PCHECK(setsockopt(fds[1], SOL_SOCKET, SO_NOSIGPIPE, &no_sigpipe,
sizeof(no_sigpipe)) == 0);
#endif // defined(OS_MACOSX)
-#endif // defined(OS_NACL) && !defined(OS_NACL_NONSFI)
+#endif // defined(OS_NACL_SFI)
server_handle_.reset(PlatformHandle(fds[0]));
DCHECK(server_handle_.is_valid());
« no previous file with comments | « ipc/mojo/ipc_mojo_bootstrap.cc ('k') | mojo/edk/embedder/platform_channel_utils_posix.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698