Commit 749bb1db authored by André Hentschel's avatar André Hentschel Committed by Alexandre Julliard

ws2_32/tests: Don't test functions directly when reporting WSAGetLastError().

parent 3cefe776
...@@ -3571,7 +3571,8 @@ static void test_events(int useMessages) ...@@ -3571,7 +3571,8 @@ static void test_events(int useMessages)
goto end; goto end;
} }
ok(!set_blocking(src, TRUE), "set_blocking failed, error %d\n", WSAGetLastError()); ret = set_blocking(src, TRUE);
ok(!ret, "set_blocking failed, error %d\n", WSAGetLastError());
src2 = socket(AF_INET, SOCK_STREAM, 0); src2 = socket(AF_INET, SOCK_STREAM, 0);
if (src2 == INVALID_SOCKET) if (src2 == INVALID_SOCKET)
...@@ -3580,7 +3581,8 @@ static void test_events(int useMessages) ...@@ -3580,7 +3581,8 @@ static void test_events(int useMessages)
goto end; goto end;
} }
ok(!set_blocking(src2, TRUE), "set_blocking failed, error %d\n", WSAGetLastError()); ret = set_blocking(src2, TRUE);
ok(!ret, "set_blocking failed, error %d\n", WSAGetLastError());
len = sizeof(BOOL); len = sizeof(BOOL);
if (getsockopt(src, SOL_SOCKET, SO_OOBINLINE, (void *)&bret, &len) == SOCKET_ERROR) if (getsockopt(src, SOL_SOCKET, SO_OOBINLINE, (void *)&bret, &len) == SOCKET_ERROR)
...@@ -4013,7 +4015,8 @@ static void test_events(int useMessages) ...@@ -4013,7 +4015,8 @@ static void test_events(int useMessages)
goto end; goto end;
} }
ok(!set_blocking(src, TRUE), "set_blocking failed, error %d\n", WSAGetLastError()); ret = set_blocking(src, TRUE);
ok(!ret, "set_blocking failed, error %d\n", WSAGetLastError());
ret = WSAAsyncSelect(src2, hWnd, WM_SOCKET, 0); ret = WSAAsyncSelect(src2, hWnd, WM_SOCKET, 0);
if (ret) if (ret)
...@@ -4022,7 +4025,8 @@ static void test_events(int useMessages) ...@@ -4022,7 +4025,8 @@ static void test_events(int useMessages)
goto end; goto end;
} }
ok(!set_blocking(src2, TRUE), "set_blocking failed, error %d\n", WSAGetLastError()); ret = set_blocking(src2, TRUE);
ok(!ret, "set_blocking failed, error %d\n", WSAGetLastError());
} }
else else
{ {
...@@ -4033,7 +4037,8 @@ static void test_events(int useMessages) ...@@ -4033,7 +4037,8 @@ static void test_events(int useMessages)
goto end; goto end;
} }
ok(!set_blocking(src, TRUE), "set_blocking failed, error %d\n", WSAGetLastError()); ret = set_blocking(src, TRUE);
ok(!ret, "set_blocking failed, error %d\n", WSAGetLastError());
ret = WSAEventSelect(src2, hEvent2, 0); ret = WSAEventSelect(src2, hEvent2, 0);
if (ret) if (ret)
...@@ -4042,7 +4047,8 @@ static void test_events(int useMessages) ...@@ -4042,7 +4047,8 @@ static void test_events(int useMessages)
goto end; goto end;
} }
ok(!set_blocking(src2, TRUE), "set_blocking failed, error %d\n", WSAGetLastError()); ret = set_blocking(src2, TRUE);
ok(!ret, "set_blocking failed, error %d\n", WSAGetLastError());
} }
end: end:
......
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