Skia roll f73c237291b:8d84c995319
[chromium-blink-merge.git] / remoting / host / host_exit_codes.h
blob81f19edb54a4acd19918297504cbbcb7fcbf1248
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef REMOTING_HOST_HOST_EXIT_CODES_H_
6 #define REMOTING_HOST_HOST_EXIT_CODES_H_
8 namespace remoting {
10 // Known host exit codes. The exit codes indicating permanent errors must be in
11 // sync with:
12 // - remoting/host/installer/mac/PrivilegedHelperTools/
13 // org.chromium.chromoting.me2me.sh
14 // - remoting/host/linux/linux_me2me_host.py
15 enum HostExitCodes {
16 // Error codes that don't indicate a permanent error condition.
17 kSuccessExitCode = 0,
18 kReservedForX11ExitCode = 1,
19 kInitializationFailed = 2,
20 kUsageExitCode = 3,
22 // Error codes that do indicate a permanent error condition.
23 kInvalidHostConfigurationExitCode = 100,
24 kInvalidHostIdExitCode = 101,
25 kInvalidOauthCredentialsExitCode = 102,
26 kInvalidHostDomainExitCode = 103,
27 kLoginScreenNotSupportedExitCode = 104,
28 kUsernameMismatchExitCode = 105,
30 // The range of the exit codes that should be interpreted as a permanent error
31 // condition.
32 kMinPermanentErrorExitCode = kInvalidHostConfigurationExitCode,
33 kMaxPermanentErrorExitCode = kUsernameMismatchExitCode
36 const char* ExitCodeToString(HostExitCodes exit_code);
37 } // namespace remoting
39 #endif // REMOTING_HOST_HOST_EXIT_CODES_H_