Commit 2c70e08c authored by Alexandre Julliard's avatar Alexandre Julliard

netapi32: Fix wrap-around bug in tick count comparison.

parent e089295f
......@@ -297,7 +297,7 @@ static UCHAR NetBTWaitForNameResponse(const NetBTAdapter *adapter, SOCKET fd,
if (fd == INVALID_SOCKET) return NRC_BADDR;
if (!answerCallback) return NRC_BADDR;
while (!found && ret == NRC_GOODRET && (now = GetTickCount()) < waitUntil)
while (!found && ret == NRC_GOODRET && (int)((now = GetTickCount()) - waitUntil) < 0)
{
DWORD msToWait = waitUntil - now;
struct fd_set fds;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment