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

Unified Diff: services/shell/tests/shell/driver.cc

Issue 2019973002: [mojo-edk] Bind a child token to child launches and port reservations. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 6 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
« no previous file with comments | « services/shell/runner/host/child_process_host.cc ('k') | services/shell/tests/util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/shell/tests/shell/driver.cc
diff --git a/services/shell/tests/shell/driver.cc b/services/shell/tests/shell/driver.cc
index 3c43bc01dca5eba3dadcaa8df2ba56ac1b2958d0..c62d109f2d551991e70505280a10de54bd287834 100644
--- a/services/shell/tests/shell/driver.cc
+++ b/services/shell/tests/shell/driver.cc
@@ -73,8 +73,10 @@ class Driver : public shell::ShellClient,
platform_channel_pair.PrepareToPassClientHandleToChildProcess(
&child_command_line, &handle_passing_info);
+ std::string child_token = mojo::edk::GenerateRandomToken();
shell::mojom::ShellClientPtr client =
- shell::PassShellClientRequestOnCommandLine(&child_command_line);
+ shell::PassShellClientRequestOnCommandLine(&child_command_line,
+ child_token);
shell::mojom::PIDReceiverPtr receiver;
shell::Identity target("exe:shell_unittest_target",
@@ -96,7 +98,8 @@ class Driver : public shell::ShellClient,
DCHECK(target_.IsValid());
receiver->SetPID(target_.Pid());
mojo::edk::ChildProcessLaunched(target_.Handle(),
- platform_channel_pair.PassServerHandle());
+ platform_channel_pair.PassServerHandle(),
+ child_token);
}
bool AcceptConnection(shell::Connection* connection) override {
« no previous file with comments | « services/shell/runner/host/child_process_host.cc ('k') | services/shell/tests/util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698