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

Unified Diff: chrome_frame/chrome_launcher_utils.cc

Issue 9836037: Adding policy support to Chrome Frame's launcher so that additional parameters can be passed to Chr… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address review comments from Greg Created 8 years, 9 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_frame/chrome_launcher.cc ('k') | chrome_frame/policy_settings.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome_frame/chrome_launcher_utils.cc
diff --git a/chrome_frame/chrome_launcher_utils.cc b/chrome_frame/chrome_launcher_utils.cc
index c77b9a8d763385139b71f13eeedbaec511caab50..0465b7bdca211c6fc0d2eb86503ea7ccdf5c56b5 100644
--- a/chrome_frame/chrome_launcher_utils.cc
+++ b/chrome_frame/chrome_launcher_utils.cc
@@ -15,6 +15,7 @@
#include "chrome/common/chrome_constants.h"
#include "chrome/common/chrome_switches.h"
#include "chrome_frame/chrome_frame_automation.h"
+#include "chrome_frame/policy_settings.h"
namespace {
@@ -73,6 +74,15 @@ bool CreateLaunchCommandLine(scoped_ptr<CommandLine>* command_line) {
// Shortcut for OS versions that don't need the integrity broker.
if (base::win::GetVersion() < base::win::VERSION_VISTA) {
command_line->reset(new CommandLine(GetChromeExecutablePath()));
+
+ // When we do not use the Chrome Launcher, we need to add the optional extra
+ // parameters from the group policy here (this is normally done by the
+ // chrome launcher). We don't do this when we use the launcher as the
+ // optional arguments could trip off sanitization checks and prevent Chrome
+ // from being launched.
+ const CommandLine& additional_params =
+ PolicySettings::GetInstance()->AdditionalLaunchParameters();
+ command_line->get()->AppendArguments(additional_params, false);
return true;
}
« no previous file with comments | « chrome_frame/chrome_launcher.cc ('k') | chrome_frame/policy_settings.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698