Commit 69cc9095 authored by Sebastian Lackner's avatar Sebastian Lackner Committed by Alexandre Julliard

ws2_32/tests: Wait for thread termination before cleaning up winsock.

parent 50487274
......@@ -4354,7 +4354,11 @@ end:
if (dst != INVALID_SOCKET)
closesocket(dst);
if (hThread != NULL)
{
dwRet = WaitForSingleObject(hThread, 500);
ok(dwRet == WAIT_OBJECT_0, "failed to wait for thread termination: %d\n", GetLastError());
CloseHandle(hThread);
}
if (ov.hEvent)
CloseHandle(ov.hEvent);
HeapFree(GetProcessHeap(), 0, buffer);
......
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