fix(Event): Poco EventImpl for Win32 breaks INFINITE wait #3737

This commit is contained in:
Alex Fabijanic 2022-08-10 14:10:12 +02:00
parent d6f38dba05
commit 2006327198

View File

@ -46,7 +46,8 @@ void EventImpl::waitImpl()
bool EventImpl::waitImpl(long milliseconds)
{
switch (WaitForSingleObject(_event, milliseconds + 1))
poco_assert(milliseconds != INFINITE);
switch (WaitForSingleObject(_event, milliseconds ? milliseconds : 1))
{
case WAIT_TIMEOUT:
return false;