ws2_32/tests: Don't test function directly when reporting GetLastError().

This commit is contained in:
Joris Huizer 2011-02-04 17:20:25 +01:00 committed by Alexandre Julliard
parent 26f753aec8
commit 36c76573de
1 changed files with 2 additions and 1 deletions

View File

@ -3773,7 +3773,8 @@ static void test_WSARecv(void)
ling.l_onoff = 1;
ling.l_linger = 0;
ok(!setsockopt (src, SOL_SOCKET, SO_LINGER, (char *) &ling, sizeof(ling)), "Failed to set linger %d\n", GetLastError());
iret = setsockopt (src, SOL_SOCKET, SO_LINGER, (char *) &ling, sizeof(ling));
ok(!iret, "Failed to set linger %d\n", GetLastError());
iret = WSARecv(dest, &bufs, 1, &bytesReturned, &flags, &ov, NULL);
ok(iret == SOCKET_ERROR && GetLastError() == ERROR_IO_PENDING, "WSARecv failed - %d error %d\n", iret, GetLastError());