win-wasapi: Fix timeout bug

The WaitForSignal message is supposed to return return true if the
handle was signaled, not if the wait timed out.
This commit is contained in:
jp9000
2015-04-09 08:49:38 -07:00
parent 1143b1d631
commit 75bc7d3153

View File

@@ -309,7 +309,7 @@ void WASAPISource::Reconnect()
static inline bool WaitForSignal(HANDLE handle, DWORD time)
{
return WaitForSingleObject(handle, time) == WAIT_TIMEOUT;
return WaitForSingleObject(handle, time) != WAIT_TIMEOUT;
}
#define RECONNECT_INTERVAL 3000