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

Unified Diff: remoting/host/setup/daemon_installer_win.cc

Issue 780653003: Revert of Upgrade the windows specific version of LaunchProcess to avoid raw handles. (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
« no previous file with comments | « content/zygote/zygote_linux.cc ('k') | win8/test/metro_registration_helper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/setup/daemon_installer_win.cc
diff --git a/remoting/host/setup/daemon_installer_win.cc b/remoting/host/setup/daemon_installer_win.cc
index 2968ce113c4695b3d3840bf6e15b03e5cb8020d4..39f2986cb7846514b7309d424b84dd41c3a8e878 100644
--- a/remoting/host/setup/daemon_installer_win.cc
+++ b/remoting/host/setup/daemon_installer_win.cc
@@ -102,7 +102,7 @@
private:
// Handle of the launched process.
- base::Process process_;
+ base::win::ScopedHandle process_;
// Used to determine when the launched process terminates.
base::win::ObjectWatcher process_watcher_;
@@ -300,14 +300,13 @@
kOmahaLanguage));
base::LaunchOptions options;
- process_ = base::LaunchProcess(command_line, options);
- if (!process_.IsValid()) {
+ if (!base::LaunchProcess(command_line, options, &process_)) {
result = GetLastError();
Done(HRESULT_FROM_WIN32(result));
return;
}
- if (!process_watcher_.StartWatching(process_.Handle(), this)) {
+ if (!process_watcher_.StartWatching(process_.Get(), this)) {
result = GetLastError();
Done(HRESULT_FROM_WIN32(result));
return;
@@ -317,7 +316,7 @@
void DaemonCommandLineInstallerWin::OnObjectSignaled(HANDLE object) {
// Check if the updater process returned success.
DWORD exit_code;
- if (GetExitCodeProcess(process_.Handle(), &exit_code) && exit_code == 0) {
+ if (GetExitCodeProcess(process_.Get(), &exit_code) && exit_code == 0) {
Done(S_OK);
} else {
Done(E_FAIL);
« no previous file with comments | « content/zygote/zygote_linux.cc ('k') | win8/test/metro_registration_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698