summaryrefslogtreecommitdiffstats
path: root/chrome/renderer
diff options
context:
space:
mode:
authorsehr@google.com <sehr@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2012-01-21 00:41:22 +0000
committersehr@google.com <sehr@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2012-01-21 00:41:22 +0000
commitd4362e74b269497a790eb19da357ed76fb0a2357 (patch)
tree37e1431c660612dbd1274c5a14fffa2d09d9b8ec /chrome/renderer
parent111ddfd416270b46727961a82ba531c931f2c8f5 (diff)
downloadchromium_src-d4362e74b269497a790eb19da357ed76fb0a2357.zip
chromium_src-d4362e74b269497a790eb19da357ed76fb0a2357.tar.gz
chromium_src-d4362e74b269497a790eb19da357ed76fb0a2357.tar.bz2
Revert 118553 - Add nacl private interface and state for process creation.
After invoking an interface method this will allow creation from other than RenderThread. BUG=none TEST=none Review URL: https://chromiumcodereview.appspot.com/9265027 TBR=sehr@google.com Review URL: https://chromiumcodereview.appspot.com/9131027 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@118565 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/renderer')
-rw-r--r--chrome/renderer/chrome_ppapi_interfaces.cc21
1 files changed, 2 insertions, 19 deletions
diff --git a/chrome/renderer/chrome_ppapi_interfaces.cc b/chrome/renderer/chrome_ppapi_interfaces.cc
index 2d5ab99..a01c1ee 100644
--- a/chrome/renderer/chrome_ppapi_interfaces.cc
+++ b/chrome/renderer/chrome_ppapi_interfaces.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -6,14 +6,12 @@
#include "base/command_line.h"
#include "base/logging.h"
-#include "base/lazy_instance.h"
#include "base/rand_util_c.h"
#include "base/utf_string_conversions.h"
#include "chrome/common/render_messages.h"
#include "chrome/renderer/chrome_ppb_pdf_impl.h"
#include "content/public/common/content_switches.h"
#include "content/public/renderer/render_thread.h"
-#include "ipc/ipc_sync_message_filter.h"
#include "ppapi/c/private/ppb_nacl_private.h"
#include "ppapi/c/private/ppb_pdf.h"
#include "webkit/plugins/ppapi/ppapi_interface_factory.h"
@@ -27,11 +25,6 @@ using content::RenderThread;
namespace chrome {
-namespace {
-base::LazyInstance<scoped_refptr<IPC::SyncMessageFilter> >
- g_background_thread_sender = LAZY_INSTANCE_INITIALIZER;
-} // namespace
-
#if !defined(DISABLE_NACL)
// Launch NaCl's sel_ldr process.
bool LaunchSelLdr(const char* alleged_url, int socket_count,
@@ -39,11 +32,7 @@ bool LaunchSelLdr(const char* alleged_url, int socket_count,
int* nacl_process_id) {
std::vector<nacl::FileDescriptor> sockets;
base::ProcessHandle nacl_process;
- IPC::Message::Sender* sender = RenderThread::Get();
- if (sender == NULL) {
- sender = g_background_thread_sender.Pointer()->get();
- }
- if (!sender->Send(
+ if (!RenderThread::Get()->Send(
new ChromeViewHostMsg_LaunchNaCl(
ASCIIToWide(alleged_url),
socket_count,
@@ -73,16 +62,10 @@ bool Are3DInterfacesDisabled() {
return CommandLine::ForCurrentProcess()->HasSwitch(switches::kDisable3DAPIs);
}
-void EnableBackgroundSelLdrLaunch() {
- g_background_thread_sender.Get() =
- RenderThread::Get()->GetSyncMessageFilter();
-}
-
const PPB_NaCl_Private ppb_nacl = {
&LaunchSelLdr,
&UrandomFD,
&Are3DInterfacesDisabled,
- &EnableBackgroundSelLdrLaunch,
};
class PPB_NaCl_Impl {