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

Unified Diff: components/nacl/renderer/ppb_nacl_private_impl.cc

Issue 1830853002: Make PlatformFileForTransit a class on Windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix tests. Created 4 years, 9 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
Index: components/nacl/renderer/ppb_nacl_private_impl.cc
diff --git a/components/nacl/renderer/ppb_nacl_private_impl.cc b/components/nacl/renderer/ppb_nacl_private_impl.cc
index eb325e4640b5fc8aabee9cd2dd59b93806c2aa1a..6498a1ddc45585904dd0aad11067609d09be3a2f 100644
--- a/components/nacl/renderer/ppb_nacl_private_impl.cc
+++ b/components/nacl/renderer/ppb_nacl_private_impl.cc
@@ -22,6 +22,7 @@
#include "base/location.h"
#include "base/logging.h"
#include "base/macros.h"
+#include "base/process/process_handle.h"
#include "base/single_thread_task_runner.h"
#include "base/strings/string_split.h"
#include "base/strings/string_util.h"
@@ -474,7 +475,8 @@ void PPBNaClPrivate::LaunchSelLdr(
// Duplicate the handle on the browser side instead of the renderer.
Mark Seaborn 2016/03/29 19:24:09 This comment doesn't apply any more, since you're
erikchen 2016/03/29 20:57:42 Removed the comment. Yes, the new path is secure.
// This is because BrokerGetFileForProcess isn't part of content/public, and
// it's simpler to do the duplication in the browser anyway.
- nexe_for_transit = nexe_file_info->handle;
+ nexe_for_transit = IPC::PlatformFileForTransit(nexe_file_info->handle,
+ base::GetCurrentProcId());
#else
# error Unsupported target platform.
#endif

Powered by Google App Engine
This is Rietveld 408576698