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

Unified Diff: components/nacl/loader/nacl_helper_linux.cc

Issue 695353005: Non-SFI mode: Use dummy PID for NaCl's IPC channel on Linux platform. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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 | « no previous file | ipc/ipc_channel.h » ('j') | ipc/ipc_channel_posix.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/nacl/loader/nacl_helper_linux.cc
diff --git a/components/nacl/loader/nacl_helper_linux.cc b/components/nacl/loader/nacl_helper_linux.cc
index d5b9fdf227ffccf7d095097b7182b131f265f355..8008e6b6f3e341bdf56f2ed01450fdc0cffa643e 100644
--- a/components/nacl/loader/nacl_helper_linux.cc
+++ b/components/nacl/loader/nacl_helper_linux.cc
@@ -48,6 +48,7 @@
#include "content/public/common/content_descriptors.h"
#include "content/public/common/zygote_fork_delegate_linux.h"
#include "crypto/nss_util.h"
+#include "ipc/ipc_channel.h"
#include "ipc/ipc_descriptors.h"
#include "ipc/ipc_switches.h"
#include "sandbox/linux/services/libc_urandom_override.h"
@@ -407,6 +408,7 @@ int main(int argc, char* argv[]) {
// Now do nothing in main for nacl_helper_nonsfi.
Mark Seaborn 2014/12/03 01:54:00 Can you rebase this change, so that I can see what
hidehiko 2014/12/03 17:03:19 Done.
#if !defined(__native_client_nonsfi__)
CommandLine::Init(argc, argv);
+ IPC::Channel::SetGlobalPid(-1); // Set dummy PID for IPC.
mdempsky 2014/11/07 03:05:34 Is this the right place to put this call? It look
hidehiko 2014/11/07 05:43:21 Yes, this is the right place. This is not only for
base::AtExitManager exit_manager;
base::RandUint64(); // acquire /dev/urandom fd before sandbox is raised
// Allows NSS to fopen() /dev/urandom.
« no previous file with comments | « no previous file | ipc/ipc_channel.h » ('j') | ipc/ipc_channel_posix.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698