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

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

Issue 1991953002: Implement a runtime headless mode for Linux (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 4 years 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/utility_process_host_impl.h" 5 #include "content/browser/utility_process_host_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/base_switches.h" 9 #include "base/base_switches.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after
303 303
304 #if defined(OS_WIN) 304 #if defined(OS_WIN)
305 cmd_line->AppendArg(switches::kPrefetchArgumentOther); 305 cmd_line->AppendArg(switches::kPrefetchArgumentOther);
306 #endif // defined(OS_WIN) 306 #endif // defined(OS_WIN)
307 307
308 if (no_sandbox_) 308 if (no_sandbox_)
309 cmd_line->AppendSwitch(switches::kNoSandbox); 309 cmd_line->AppendSwitch(switches::kNoSandbox);
310 310
311 // Browser command-line switches to propagate to the utility process. 311 // Browser command-line switches to propagate to the utility process.
312 static const char* const kSwitchNames[] = { 312 static const char* const kSwitchNames[] = {
313 switches::kHeadless,
313 switches::kNoSandbox, 314 switches::kNoSandbox,
314 switches::kProfilerTiming, 315 switches::kProfilerTiming,
315 #if defined(OS_MACOSX) 316 #if defined(OS_MACOSX)
316 switches::kEnableSandboxLogging, 317 switches::kEnableSandboxLogging,
317 #endif 318 #endif
318 }; 319 };
319 cmd_line->CopySwitchesFrom(browser_command_line, kSwitchNames, 320 cmd_line->CopySwitchesFrom(browser_command_line, kSwitchNames,
320 arraysize(kSwitchNames)); 321 arraysize(kSwitchNames));
321 322
322 if (has_cmd_prefix) { 323 if (has_cmd_prefix) {
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
393 base::WeakPtr<UtilityProcessHostImpl> host, 394 base::WeakPtr<UtilityProcessHostImpl> host,
394 int error_code) { 395 int error_code) {
395 if (!host) 396 if (!host)
396 return; 397 return;
397 398
398 host->OnProcessLaunchFailed(error_code); 399 host->OnProcessLaunchFailed(error_code);
399 delete host.get(); 400 delete host.get();
400 } 401 }
401 402
402 } // namespace content 403 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698