OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 # Virtual Me2Me implementation. This script runs and manages the processes | 6 # Virtual Me2Me implementation. This script runs and manages the processes |
7 # required for a Virtual Me2Me desktop, which are: X server, X desktop | 7 # required for a Virtual Me2Me desktop, which are: X server, X desktop |
8 # session, and Host process. | 8 # session, and Host process. |
9 # This script is intended to run continuously as a background daemon | 9 # This script is intended to run continuously as a background daemon |
10 # process, running under an ordinary (non-root) user account. | 10 # process, running under an ordinary (non-root) user account. |
(...skipping 856 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
867 except: | 867 except: |
868 pass | 868 pass |
869 return 0 | 869 return 0 |
870 elif os.WEXITSTATUS(status) == 4: | 870 elif os.WEXITSTATUS(status) == 4: |
871 logging.info("OAuth credentials are invalid - exiting.") | 871 logging.info("OAuth credentials are invalid - exiting.") |
872 try: | 872 try: |
873 os.remove(auth.config_file) | 873 os.remove(auth.config_file) |
874 except: | 874 except: |
875 pass | 875 pass |
876 return 0 | 876 return 0 |
| 877 elif os.WEXITSTATUS(status) == 5: |
| 878 logging.info("Host domain is blocked by policy - exiting.") |
| 879 os.remove(host.config_file) |
| 880 return 0 |
877 | 881 |
878 if __name__ == "__main__": | 882 if __name__ == "__main__": |
879 logging.basicConfig(level=logging.DEBUG) | 883 logging.basicConfig(level=logging.DEBUG) |
880 sys.exit(main()) | 884 sys.exit(main()) |
OLD | NEW |