| 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(HOST_OS_WINDOWS) | 8 #if defined(HOST_OS_WINDOWS) |
| 9 | 9 |
| 10 #include "bin/process.h" | 10 #include "bin/process.h" |
| (...skipping 960 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 971 } | 971 } |
| 972 | 972 |
| 973 | 973 |
| 974 BOOL WINAPI SignalHandler(DWORD signal) { | 974 BOOL WINAPI SignalHandler(DWORD signal) { |
| 975 MutexLocker lock(signal_mutex); | 975 MutexLocker lock(signal_mutex); |
| 976 const SignalInfo* handler = signal_handlers; | 976 const SignalInfo* handler = signal_handlers; |
| 977 bool handled = false; | 977 bool handled = false; |
| 978 while (handler != NULL) { | 978 while (handler != NULL) { |
| 979 if (handler->signal() == signal) { | 979 if (handler->signal() == signal) { |
| 980 int value = 0; | 980 int value = 0; |
| 981 SocketBase::Write(handler->fd(), &value, 1); | 981 SocketBase::Write(handler->fd(), &value, 1, SocketBase::kAsync); |
| 982 handled = true; | 982 handled = true; |
| 983 } | 983 } |
| 984 handler = handler->next(); | 984 handler = handler->next(); |
| 985 } | 985 } |
| 986 return handled; | 986 return handled; |
| 987 } | 987 } |
| 988 | 988 |
| 989 | 989 |
| 990 intptr_t GetWinSignal(intptr_t signal) { | 990 intptr_t GetWinSignal(intptr_t signal) { |
| 991 switch (signal) { | 991 switch (signal) { |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1070 } | 1070 } |
| 1071 delete handler; | 1071 delete handler; |
| 1072 } | 1072 } |
| 1073 | 1073 |
| 1074 } // namespace bin | 1074 } // namespace bin |
| 1075 } // namespace dart | 1075 } // namespace dart |
| 1076 | 1076 |
| 1077 #endif // defined(HOST_OS_WINDOWS) | 1077 #endif // defined(HOST_OS_WINDOWS) |
| 1078 | 1078 |
| 1079 #endif // !defined(DART_IO_DISABLED) | 1079 #endif // !defined(DART_IO_DISABLED) |
| OLD | NEW |