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

Side by Side Diff: content/browser/child_process_launcher.cc

Issue 1579863003: Convert Pass()→std::move() for Mac build. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/child_process_launcher.h" 5 #include "content/browser/child_process_launcher.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
241 // Make sure the MachBroker is running, and inform it to expect a 241 // Make sure the MachBroker is running, and inform it to expect a
242 // check-in from the new process. 242 // check-in from the new process.
243 broker->EnsureRunning(); 243 broker->EnsureRunning();
244 244
245 const SandboxType sandbox_type = delegate->GetSandboxType(); 245 const SandboxType sandbox_type = delegate->GetSandboxType();
246 scoped_ptr<sandbox::PreExecDelegate> pre_exec_delegate; 246 scoped_ptr<sandbox::PreExecDelegate> pre_exec_delegate;
247 if (BootstrapSandboxManager::ShouldEnable()) { 247 if (BootstrapSandboxManager::ShouldEnable()) {
248 BootstrapSandboxManager* sandbox_manager = 248 BootstrapSandboxManager* sandbox_manager =
249 BootstrapSandboxManager::GetInstance(); 249 BootstrapSandboxManager::GetInstance();
250 if (sandbox_manager->EnabledForSandbox(sandbox_type)) { 250 if (sandbox_manager->EnabledForSandbox(sandbox_type)) {
251 pre_exec_delegate = 251 pre_exec_delegate = sandbox_manager->sandbox()->NewClient(sandbox_type);
252 sandbox_manager->sandbox()->NewClient(sandbox_type).Pass();
253 } 252 }
254 } 253 }
255 options.pre_exec_delegate = pre_exec_delegate.get(); 254 options.pre_exec_delegate = pre_exec_delegate.get();
256 #endif // defined(OS_MACOSX) 255 #endif // defined(OS_MACOSX)
257 256
258 process = base::LaunchProcess(*cmd_line, options); 257 process = base::LaunchProcess(*cmd_line, options);
259 258
260 #if defined(OS_MACOSX) 259 #if defined(OS_MACOSX)
261 if (process.IsValid()) { 260 if (process.IsValid()) {
262 broker->AddPlaceholderForPid(process.Pid(), child_process_id); 261 broker->AddPlaceholderForPid(process.Pid(), child_process_id);
(...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after
521 } 520 }
522 521
523 ChildProcessLauncher::Client* ChildProcessLauncher::ReplaceClientForTest( 522 ChildProcessLauncher::Client* ChildProcessLauncher::ReplaceClientForTest(
524 Client* client) { 523 Client* client) {
525 Client* ret = client_; 524 Client* ret = client_;
526 client_ = client; 525 client_ = client;
527 return ret; 526 return ret;
528 } 527 }
529 528
530 } // namespace content 529 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698