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

Unified Diff: chrome/app/chrome_main.cc

Issue 2832963002: Reland of Add --headless flag to Windows (Closed)
Patch Set: Created 3 years, 8 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 | « chrome/BUILD.gn ('k') | headless/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/app/chrome_main.cc
diff --git a/chrome/app/chrome_main.cc b/chrome/app/chrome_main.cc
index 2cc37702d9cd2f141e9a5a37cc81dc078c288f66..3ac247fddd943ac2f9ed5d91e4456f572a6bf240 100644
--- a/chrome/app/chrome_main.cc
+++ b/chrome/app/chrome_main.cc
@@ -89,22 +89,20 @@
#else
params.argc = argc;
params.argv = argv;
-#endif
-
-#if !defined(OS_WIN)
base::CommandLine::Init(params.argc, params.argv);
+#endif // defined(OS_WIN)
+ base::CommandLine::Init(0, nullptr);
const base::CommandLine* command_line(base::CommandLine::ForCurrentProcess());
ALLOW_UNUSED_LOCAL(command_line);
-#endif
-#if defined(OS_LINUX) || defined(OS_MACOSX)
+#if defined(OS_LINUX) || defined(OS_MACOSX) || defined(OS_WIN)
if (command_line->HasSwitch(switches::kHeadless)) {
#if defined(OS_MACOSX)
SetUpBundleOverrides();
#endif
- return headless::HeadlessShellMain(argc, argv);
+ return headless::HeadlessShellMain(params);
}
-#endif // defined(OS_LINUX) || defined(OS_MACOSX)
+#endif // defined(OS_LINUX) || defined(OS_MACOSX) || defined(OS_WIN)
#if defined(OS_CHROMEOS) && BUILDFLAG(ENABLE_PACKAGE_MASH_SERVICES)
version_info::Channel channel = chrome::GetChannel();
« no previous file with comments | « chrome/BUILD.gn ('k') | headless/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698