Merge eba6b33fb49da92da31133030ef5c9678f4a7220 into 34f7fa22022bed9e0e390ed3580a1c83ac4a2834

This commit is contained in:
Denis Zibarev 2025-03-28 07:06:51 +00:00 committed by GitHub
commit 1146b8edc3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -564,10 +564,19 @@ int zmq::socket_poller_t::wait (zmq::socket_poller_t::event_t *events_,
// Wait for events.
const int rc = poll (_pollfds, _pollset_size, timeout);
#if defined ZMQ_HAVE_WINDOWS
if (unlikely (rc == SOCKET_ERROR)) {
errno = wsa_error_to_errno (WSAGetLastError ());
if (errno == EINTR || errno == EAGAIN)
return -1;
}
#else
if (rc == -1 && errno == EINTR) {
return -1;
}
errno_assert (rc >= 0);
#endif
// Receive the signal from pollfd
if (_use_signaler && _pollfds[0].revents & POLLIN)