| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #if !defined(DART_IO_DISABLED) | 5 #if !defined(DART_IO_DISABLED) |
| 6 | 6 |
| 7 #include "platform/globals.h" | 7 #include "platform/globals.h" |
| 8 #if defined(TARGET_OS_WINDOWS) | 8 #if defined(TARGET_OS_WINDOWS) |
| 9 | 9 |
| 10 #include "bin/process.h" | 10 #include "bin/process.h" |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 #include "bin/utils_win.h" | 22 #include "bin/utils_win.h" |
| 23 | 23 |
| 24 namespace dart { | 24 namespace dart { |
| 25 namespace bin { | 25 namespace bin { |
| 26 | 26 |
| 27 static const int kReadHandle = 0; | 27 static const int kReadHandle = 0; |
| 28 static const int kWriteHandle = 1; | 28 static const int kWriteHandle = 1; |
| 29 | 29 |
| 30 int Process::global_exit_code_ = 0; | 30 int Process::global_exit_code_ = 0; |
| 31 Mutex* Process::global_exit_code_mutex_ = new Mutex(); | 31 Mutex* Process::global_exit_code_mutex_ = new Mutex(); |
| 32 Process::ExitHook Process::exit_hook_ = NULL; |
| 32 | 33 |
| 33 // ProcessInfo is used to map a process id to the process handle, | 34 // ProcessInfo is used to map a process id to the process handle, |
| 34 // wait handle for registered exit code event and the pipe used to | 35 // wait handle for registered exit code event and the pipe used to |
| 35 // communicate the exit code of the process to Dart. | 36 // communicate the exit code of the process to Dart. |
| 36 // ProcessInfo objects are kept in the static singly-linked | 37 // ProcessInfo objects are kept in the static singly-linked |
| 37 // ProcessInfoList. | 38 // ProcessInfoList. |
| 38 class ProcessInfo { | 39 class ProcessInfo { |
| 39 public: | 40 public: |
| 40 ProcessInfo(DWORD process_id, | 41 ProcessInfo(DWORD process_id, |
| 41 HANDLE process_handle, | 42 HANDLE process_handle, |
| (...skipping 1039 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1081 } | 1082 } |
| 1082 delete handler; | 1083 delete handler; |
| 1083 } | 1084 } |
| 1084 | 1085 |
| 1085 } // namespace bin | 1086 } // namespace bin |
| 1086 } // namespace dart | 1087 } // namespace dart |
| 1087 | 1088 |
| 1088 #endif // defined(TARGET_OS_WINDOWS) | 1089 #endif // defined(TARGET_OS_WINDOWS) |
| 1089 | 1090 |
| 1090 #endif // !defined(DART_IO_DISABLED) | 1091 #endif // !defined(DART_IO_DISABLED) |
| OLD | NEW |