diff options
-rw-r--r-- | chrome/installer/util/google_chrome_distribution.cc | 7 | ||||
-rw-r--r-- | chrome/installer/util/helper.cc | 2 |
2 files changed, 4 insertions, 5 deletions
diff --git a/chrome/installer/util/google_chrome_distribution.cc b/chrome/installer/util/google_chrome_distribution.cc index 38474cc..56e3808 100644 --- a/chrome/installer/util/google_chrome_distribution.cc +++ b/chrome/installer/util/google_chrome_distribution.cc @@ -450,6 +450,8 @@ void GoogleChromeDistribution::LaunchUserExperiment( } } LOG(INFO) << "User drafted for toast experiment"; + if (!GoogleUpdateSettings::SetClient(kToastExpBaseGroup)) + return; // The experiment needs to be performed in a different process because // google_update expects the upgrade process to be quick and nimble. RelaunchSetup(installer_util::switches::kInactiveUserToast); @@ -458,11 +460,8 @@ void GoogleChromeDistribution::LaunchUserExperiment( void GoogleChromeDistribution::InactiveUserToastExperiment() { // User qualifies for the experiment. Launch chrome with --try-chrome. Before // that we need to change the client so we can track the progress. - if (!GoogleUpdateSettings::SetClient(kToastExpBaseGroup)) - return; int32 exit_code = 0; - std::wstring option(L"--"); - option.append(switches::kTryChromeAgain); + std::wstring option(std::wstring(L" --") + switches::kTryChromeAgain); if (!installer::LaunchChromeAndWaitForResult(false, option, &exit_code)) return; // The chrome process has exited, figure out what happened. diff --git a/chrome/installer/util/helper.cc b/chrome/installer/util/helper.cc index a52f6b5..a87bcf9 100644 --- a/chrome/installer/util/helper.cc +++ b/chrome/installer/util/helper.cc @@ -61,7 +61,7 @@ bool installer::LaunchChromeAndWaitForResult(bool system_install, return false; file_util::AppendToPath(&chrome_exe, installer_util::kChromeExe); - std::wstring command_line(chrome_exe); + std::wstring command_line(L"\"" + chrome_exe + L"\""); command_line.append(options); STARTUPINFOW si = {sizeof(si)}; PROCESS_INFORMATION pi = {0}; |