mirror of
https://github.com/pocoproject/poco.git
synced 2025-04-23 16:52:44 +02:00
fix poll/WSAPoll on Windows
This commit is contained in:
parent
6559c5bac7
commit
9626aba20b
@ -509,8 +509,11 @@ bool SocketImpl::poll(const Poco::Timespan& timeout, int mode)
|
|||||||
do
|
do
|
||||||
{
|
{
|
||||||
Poco::Timestamp start;
|
Poco::Timestamp start;
|
||||||
|
#ifdef _WIN32
|
||||||
|
rc = WSAPoll(&pollBuf, 1, static_cast<INT>(remainingTime.totalMilliseconds()));
|
||||||
|
#else
|
||||||
rc = ::poll(&pollBuf, 1, remainingTime.totalMilliseconds());
|
rc = ::poll(&pollBuf, 1, remainingTime.totalMilliseconds());
|
||||||
|
#endif
|
||||||
if (rc < 0 && lastError() == POCO_EINTR)
|
if (rc < 0 && lastError() == POCO_EINTR)
|
||||||
{
|
{
|
||||||
Poco::Timestamp end;
|
Poco::Timestamp end;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user