summaryrefslogtreecommitdiffstats
path: root/chrome/nacl
diff options
context:
space:
mode:
authorbbudge@chromium.org <bbudge@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-21 23:46:54 +0000
committerbbudge@chromium.org <bbudge@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-21 23:46:54 +0000
commitca8bf671623c033e58d19cc62fc82cf419b8ff80 (patch)
tree752430ca8bf0ec08b5c67cfe5221d18c318183cd /chrome/nacl
parentb6f81374624c50edd6f4568eb1bacb3f05ed635b (diff)
downloadchromium_src-ca8bf671623c033e58d19cc62fc82cf419b8ff80.zip
chromium_src-ca8bf671623c033e58d19cc62fc82cf419b8ff80.tar.gz
chromium_src-ca8bf671623c033e58d19cc62fc82cf419b8ff80.tar.bz2
Revert 143483 - Add an IPC channel between the NaCl loader process and the renderer.
BUG=116317 TEST=manual Review URL: https://chromiumcodereview.appspot.com/10214007 TBR=bbudge@chromium.org Review URL: https://chromiumcodereview.appspot.com/10635014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@143491 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/nacl')
-rw-r--r--chrome/nacl/nacl_ipc_adapter.cc7
-rw-r--r--chrome/nacl/nacl_ipc_adapter.h4
-rw-r--r--chrome/nacl/nacl_listener.cc27
3 files changed, 1 insertions, 37 deletions
diff --git a/chrome/nacl/nacl_ipc_adapter.cc b/chrome/nacl/nacl_ipc_adapter.cc
index f915a6a..f76fa0d 100644
--- a/chrome/nacl/nacl_ipc_adapter.cc
+++ b/chrome/nacl/nacl_ipc_adapter.cc
@@ -74,7 +74,6 @@ ssize_t NaClDescCustomRecvMsg(void* handle, NaClImcTypedMsgHdr* msg,
int /* flags */) {
if (msg->iov_length != 1)
return -1;
- msg->ndesc_length = 0; // Messages with descriptors aren't supported yet.
return static_cast<ssize_t>(
ToAdapter(handle)->BlockingReceive(static_cast<char*>(msg->iov[0].base),
msg->iov[0].length));
@@ -282,12 +281,6 @@ NaClDesc* NaClIPCAdapter::MakeNaClDesc() {
return MakeNaClDescCustom(this);
}
-#if defined(OS_POSIX)
-int NaClIPCAdapter::TakeClientFileDescriptor() {
- return io_thread_data_.channel_->TakeClientFileDescriptor();
-}
-#endif
-
bool NaClIPCAdapter::OnMessageReceived(const IPC::Message& message) {
{
base::AutoLock lock(lock_);
diff --git a/chrome/nacl/nacl_ipc_adapter.h b/chrome/nacl/nacl_ipc_adapter.h
index 8c3c493..12500cd 100644
--- a/chrome/nacl/nacl_ipc_adapter.h
+++ b/chrome/nacl/nacl_ipc_adapter.h
@@ -77,10 +77,6 @@ class NaClIPCAdapter : public base::RefCountedThreadSafe<NaClIPCAdapter>,
// NaClDesc is reference-counted, and a reference is returned.
NaClDesc* MakeNaClDesc();
-#if defined(OS_POSIX)
- int TakeClientFileDescriptor();
-#endif
-
// Listener implementation.
virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
virtual void OnChannelConnected(int32 peer_pid) OVERRIDE;
diff --git a/chrome/nacl/nacl_listener.cc b/chrome/nacl/nacl_listener.cc
index 7159749..a5433dc 100644
--- a/chrome/nacl/nacl_listener.cc
+++ b/chrome/nacl/nacl_listener.cc
@@ -13,19 +13,13 @@
#include "base/message_loop.h"
#include "base/rand_util.h"
#include "chrome/common/nacl_messages.h"
-#include "chrome/nacl/nacl_ipc_adapter.h"
#include "chrome/nacl/nacl_validation_db.h"
#include "chrome/nacl/nacl_validation_query.h"
-#include "ipc/ipc_channel_handle.h"
-#include "ipc/ipc_switches.h"
#include "ipc/ipc_sync_channel.h"
#include "ipc/ipc_sync_message_filter.h"
+#include "ipc/ipc_switches.h"
#include "native_client/src/trusted/service_runtime/sel_main_chrome.h"
-#if defined(OS_POSIX)
-#include "base/file_descriptor_posix.h"
-#endif
-
#if defined(OS_LINUX)
#include "content/public/common/child_process_sandbox_support_linux.h"
#endif
@@ -194,25 +188,6 @@ void NaClListener::OnMsgStart(const nacl::NaClStartParams& params) {
return;
}
- if (params.enable_ipc_proxy) {
- // Create the server side of the channel and notify the process host so it
- // can reply to the renderer, which will connect as client.
- IPC::ChannelHandle channel_handle =
- IPC::Channel::GenerateVerifiedChannelID("nacl");
-
- scoped_refptr<NaClIPCAdapter> ipc_adapter(new NaClIPCAdapter(
- channel_handle, io_thread_.message_loop_proxy()));
- args->initial_ipc_desc = ipc_adapter.get()->MakeNaClDesc();
-
-#if defined(OS_POSIX)
- channel_handle.socket = base::FileDescriptor(
- ipc_adapter.get()->TakeClientFileDescriptor(), true);
-#endif
-
- if (!Send(new NaClProcessHostMsg_PpapiChannelCreated(channel_handle)))
- LOG(ERROR) << "Failed to send IPC channel handle to renderer.";
- }
-
std::vector<nacl::FileDescriptor> handles = params.handles;
#if defined(OS_LINUX) || defined(OS_MACOSX)