| Index: runtime/bin/eventhandler_macos.cc
|
| diff --git a/runtime/bin/eventhandler_macos.cc b/runtime/bin/eventhandler_macos.cc
|
| index beeae4b50f5bb4240a903b577b52a298fc8b7fdd..eb01d188d3d9d122da45feac0b701d3829d9f8ad 100644
|
| --- a/runtime/bin/eventhandler_macos.cc
|
| +++ b/runtime/bin/eventhandler_macos.cc
|
| @@ -179,7 +179,7 @@ void EventHandlerImplementation::WakeupHandler(intptr_t id,
|
| void EventHandlerImplementation::HandleInterruptFd() {
|
| const intptr_t MAX_MESSAGES = kInterruptMessageSize;
|
| InterruptMessage msg[MAX_MESSAGES];
|
| - ssize_t bytes = TEMP_FAILURE_RETRY(
|
| + ssize_t bytes = TEMP_FAILURE_RETRY_NO_SIGNAL_BLOCKER(
|
| read(interrupt_fds_[0], msg, MAX_MESSAGES * kInterruptMessageSize));
|
| for (ssize_t i = 0; i < bytes / kInterruptMessageSize; i++) {
|
| if (msg[i].id == kTimerId) {
|
| @@ -348,6 +348,7 @@ void EventHandlerImplementation::HandleTimeout() {
|
|
|
|
|
| void EventHandlerImplementation::EventHandlerEntry(uword args) {
|
| + ThreadSignalBlocker signal_blocker(SIGPROF);
|
| static const intptr_t kMaxEvents = 16;
|
| struct kevent events[kMaxEvents];
|
| EventHandler* handler = reinterpret_cast<EventHandler*>(args);
|
| @@ -368,12 +369,8 @@ void EventHandlerImplementation::EventHandlerEntry(uword args) {
|
| ts.tv_nsec = (millis32 - (secs * 1000)) * 1000000;
|
| timeout = &ts;
|
| }
|
| - intptr_t result = TEMP_FAILURE_RETRY(kevent(handler_impl->kqueue_fd_,
|
| - NULL,
|
| - 0,
|
| - events,
|
| - kMaxEvents,
|
| - timeout));
|
| + intptr_t result = TEMP_FAILURE_RETRY_NO_SIGNAL_BLOCKER(
|
| + kevent(handler_impl->kqueue_fd_, NULL, 0, events, kMaxEvents, timeout));
|
| if (result == -1) {
|
| const int kBufferSize = 1024;
|
| char error_message[kBufferSize];
|
|
|