summaryrefslogtreecommitdiffstats
path: root/ipc
diff options
context:
space:
mode:
authormcgrathr@chromium.org <mcgrathr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-06-05 23:37:11 +0000
committermcgrathr@chromium.org <mcgrathr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-06-05 23:37:11 +0000
commit18ff3c38542bdc3186b1a8512bdc9edef69acff0 (patch)
tree4d3cc517c9621f9702b4239a5f1a9dba7463577e /ipc
parentac2256248677c5ca7d1117c686ed7619747b1e3d (diff)
downloadchromium_src-18ff3c38542bdc3186b1a8512bdc9edef69acff0.zip
chromium_src-18ff3c38542bdc3186b1a8512bdc9edef69acff0.tar.gz
chromium_src-18ff3c38542bdc3186b1a8512bdc9edef69acff0.tar.bz2
Use native_client/src/public/ for IMC headers
The preferred way to get the header files for NaCl's IMC layer has changed. The NaClImcMsgIoVec and NaClImcMsgHdr structs now use the NaclAbi prefix. BUG= https://code.google.com/p/nativeclient/issues/detail?id=3464 TEST= R=dmichael@chromium.org, mseaborn@chromium.org Review URL: https://chromiumcodereview.appspot.com/15793014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@204359 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ipc')
-rw-r--r--ipc/DEPS4
-rw-r--r--ipc/ipc_channel_nacl.cc16
2 files changed, 14 insertions, 6 deletions
diff --git a/ipc/DEPS b/ipc/DEPS
new file mode 100644
index 0000000..eea2192
--- /dev/null
+++ b/ipc/DEPS
@@ -0,0 +1,4 @@
+include_rules = [
+ # For ipc_channel_nacl.cc:
+ "+native_client/src/public",
+]
diff --git a/ipc/ipc_channel_nacl.cc b/ipc/ipc_channel_nacl.cc
index 805e906..6213d41 100644
--- a/ipc/ipc_channel_nacl.cc
+++ b/ipc/ipc_channel_nacl.cc
@@ -6,8 +6,6 @@
#include <errno.h>
#include <stddef.h>
-#include <sys/nacl_imc_api.h>
-#include <sys/nacl_syscalls.h>
#include <sys/types.h>
#include <algorithm>
@@ -21,6 +19,8 @@
#include "base/threading/simple_thread.h"
#include "ipc/file_descriptor_set_posix.h"
#include "ipc/ipc_logging.h"
+#include "native_client/src/public/imc_syscalls.h"
+#include "native_client/src/public/imc_types.h"
namespace IPC {
@@ -39,8 +39,10 @@ bool ReadDataOnReaderThread(int pipe, MessageContents* contents) {
contents->data.resize(Channel::kReadBufferSize);
contents->fds.resize(FileDescriptorSet::kMaxDescriptorsPerMessage);
- NaClImcMsgIoVec iov = { &contents->data[0], contents->data.size() };
- NaClImcMsgHdr msg = { &iov, 1, &contents->fds[0], contents->fds.size() };
+ NaClAbiNaClImcMsgIoVec iov = { &contents->data[0], contents->data.size() };
+ NaClAbiNaClImcMsgHdr msg = {
+ &iov, 1, &contents->fds[0], contents->fds.size()
+ };
int bytes_read = imc_recvmsg(pipe, &msg, 0);
@@ -264,8 +266,10 @@ bool Channel::ChannelImpl::ProcessOutgoingMessages() {
DCHECK(num_fds <= FileDescriptorSet::kMaxDescriptorsPerMessage);
msg->file_descriptor_set()->GetDescriptors(fds);
- NaClImcMsgIoVec iov = { const_cast<void*>(msg->data()), msg->size() };
- NaClImcMsgHdr msgh = { &iov, 1, fds, num_fds };
+ NaClAbiNaClImcMsgIoVec iov = {
+ const_cast<void*>(msg->data()), msg->size()
+ };
+ NaClAbiNaClImcMsgHdr msgh = { &iov, 1, fds, num_fds };
ssize_t bytes_written = imc_sendmsg(pipe_, &msgh, 0);
DCHECK(bytes_written); // The trusted side shouldn't return 0.