Index: content/browser/mach_broker_mac_unittest.cc |
diff --git a/content/browser/mach_broker_mac_unittest.cc b/content/browser/mach_broker_mac_unittest.cc |
index 261f500a5635d4474e182b679aa9dc858007ddd5..a170d43cfc36343cafa5613fdbc79586ec965ca4 100644 |
--- a/content/browser/mach_broker_mac_unittest.cc |
+++ b/content/browser/mach_broker_mac_unittest.cc |
@@ -42,14 +42,15 @@ class MachBrokerTest : public testing::Test, |
return broker_.child_process_id_map_.count(child_process_id); |
} |
- base::Process LaunchTestChild(const std::string& function, |
- int child_process_id) { |
+ base::SpawnChildResult LaunchTestChild(const std::string& function, |
+ int child_process_id) { |
base::AutoLock lock(broker_.GetLock()); |
- base::Process test_child_process = base::SpawnMultiProcessTestChild( |
+ base::SpawnChildResult spawn_child = base::SpawnMultiProcessTestChild( |
function, base::GetMultiProcessTestChildBaseCommandLine(), |
base::LaunchOptions()); |
- broker_.AddPlaceholderForPid(test_child_process.Handle(), child_process_id); |
- return test_child_process; |
+ broker_.AddPlaceholderForPid(spawn_child.process.Handle(), |
+ child_process_id); |
+ return spawn_child; |
} |
void WaitForChildExit(base::Process& process) { |
@@ -91,22 +92,23 @@ TEST_F(MachBrokerTest, AddChildProcess) { |
base::AutoLock lock(broker_.GetLock()); |
broker_.EnsureRunning(); |
} |
- base::Process child_process = LaunchTestChild("MachBrokerTestChild", 7); |
+ base::SpawnChildResult spawn_child = |
+ LaunchTestChild("MachBrokerTestChild", 7); |
WaitForTaskPort(); |
- EXPECT_EQ(child_process.Handle(), received_process_); |
- WaitForChildExit(child_process); |
+ EXPECT_EQ(spawn_child.process.Handle(), received_process_); |
+ WaitForChildExit(spawn_child.process); |
EXPECT_NE(static_cast<mach_port_t>(MACH_PORT_NULL), |
- broker_.TaskForPid(child_process.Handle())); |
+ broker_.TaskForPid(spawn_child.process.Handle())); |
EXPECT_EQ(1, GetChildProcessCount(7)); |
// Should be no entry for any other PID. |
EXPECT_EQ(static_cast<mach_port_t>(MACH_PORT_NULL), |
- broker_.TaskForPid(child_process.Handle() + 1)); |
+ broker_.TaskForPid(spawn_child.process.Handle() + 1)); |
InvalidateChildProcessId(7); |
EXPECT_EQ(static_cast<mach_port_t>(MACH_PORT_NULL), |
- broker_.TaskForPid(child_process.Handle())); |
+ broker_.TaskForPid(spawn_child.process.Handle())); |
EXPECT_EQ(0, GetChildProcessCount(7)); |
} |