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

Unified Diff: remoting/host/wts_session_process_launcher_win.cc

Issue 10106013: Chromoting: stopping the service if the host ID is permanently not recognized by the could. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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
Index: remoting/host/wts_session_process_launcher_win.cc
diff --git a/remoting/host/wts_session_process_launcher_win.cc b/remoting/host/wts_session_process_launcher_win.cc
index eced4f5cfa6c4602967bb8b924a5dd1df893b782..7824be9b3318ffb2f0b5d048d76228fbd2273d61 100644
--- a/remoting/host/wts_session_process_launcher_win.cc
+++ b/remoting/host/wts_session_process_launcher_win.cc
@@ -26,7 +26,7 @@
#include "ipc/ipc_channel_proxy.h"
#include "ipc/ipc_message.h"
#include "ipc/ipc_message_macros.h"
-
+#include "remoting/host/constants.h"
#include "remoting/host/chromoting_messages.h"
#include "remoting/host/sas_injector.h"
#include "remoting/host/wts_console_monitor_win.h"
@@ -36,10 +36,6 @@ using base::TimeDelta;
namespace {
-// The exit code returned by the host process when its configuration is not
-// valid.
-const int kInvalidHostConfigurationExitCode = 1;
-
// The minimum and maximum delays between attempts to inject host process into
// a session.
const int kMaxLaunchDelaySeconds = 60;
@@ -351,8 +347,9 @@ void WtsSessionProcessLauncher::OnObjectSignaled(HANDLE object) {
// Stop trying to restart the host if its process exited due to
// misconfiguration.
DWORD exit_code;
- bool stop_trying = GetExitCodeProcess(process_.handle(), &exit_code) &&
- exit_code == kInvalidHostConfigurationExitCode;
+ bool stop_trying = GetExitCodeProcess(process_.handle(), &exit_code) && (
simonmorris 2012/04/17 00:46:43 It would be safer to put this logic in cross-platf
alexeypa (please no reviews) 2012/04/17 18:35:53 Done.
+ exit_code == kInvalidHostConfigurationExitCode ||
+ exit_code == kInvalidHostIdExitCode);
// The host process has been terminated for some reason. The handle can now be
// closed.

Powered by Google App Engine
This is Rietveld 408576698