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

Unified Diff: chrome/browser/first_run/first_run_internal_win.cc

Issue 785373002: Update browser/first_run to use the new version of LaunchProcess. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/first_run/first_run_internal_win.cc
diff --git a/chrome/browser/first_run/first_run_internal_win.cc b/chrome/browser/first_run/first_run_internal_win.cc
index d11e4f9e4698618b7acafabdaf9b6a93889074ed..f66e95a23be80c34269a9007d019506870a18daf 100644
--- a/chrome/browser/first_run/first_run_internal_win.cc
+++ b/chrome/browser/first_run/first_run_internal_win.cc
@@ -46,7 +46,6 @@ bool LaunchSetupForEula(const base::FilePath::StringType& value,
return false;
exe_dir = exe_dir.Append(installer::kInstallerDir);
base::FilePath exe_path = exe_dir.Append(installer::kSetupExe);
- base::ProcessHandle ph;
CommandLine cl(CommandLine::NO_PROGRAM);
cl.AppendSwitchNative(installer::switches::kShowEula, value);
@@ -67,11 +66,11 @@ bool LaunchSetupForEula(const base::FilePath::StringType& value,
CommandLine setup_path(exe_path);
setup_path.AppendArguments(cl, false);
+ base::Process process =
+ base::LaunchProcess(setup_path, base::LaunchOptions());
int exit_code = 0;
- if (!base::LaunchProcess(setup_path, base::LaunchOptions(), &ph) ||
- !base::WaitForExitCode(ph, &exit_code)) {
+ if (!process.IsValid() || !process.WaitForExit(&exit_code))
return false;
- }
*ret_code = exit_code;
return true;
« no previous file with comments | « no previous file | chrome/browser/first_run/upgrade_util_win.cc » ('j') | chrome/browser/first_run/upgrade_util_win.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698