Also fixes spurious test failures wherein the broken call would return ENOTSOCK.
Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com>
---
dlls/ws2_32/tests/afd.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/ws2_32/tests/afd.c b/dlls/ws2_32/tests/afd.c
index 97b35e1f3ea..3f03c14a94f 100644
--- a/dlls/ws2_32/tests/afd.c
+++ b/dlls/ws2_32/tests/afd.c
@@ -565,7 +565,7 @@ static void test_poll(void)
ret = bind(client, (const struct sockaddr *)&bind_addr, sizeof(bind_addr));
ok(!ret, "got error %u\n", WSAGetLastError());
len = sizeof(addr);
- ret = getsockname(listener, (struct sockaddr *)&addr, &len);
+ ret = getsockname(client, (struct sockaddr *)&addr, &len);
ok(!ret, "got error %u\n", WSAGetLastError());
check_poll(client, event, AFD_POLL_WRITE);
@@ -1046,7 +1046,7 @@ static void test_recv(void)
ret = bind(client, (const struct sockaddr *)&bind_addr, sizeof(bind_addr));
ok(!ret, "got error %u\n", WSAGetLastError());
len = sizeof(addr);
- ret = getsockname(listener, (struct sockaddr *)&addr, &len);
+ ret = getsockname(client, (struct sockaddr *)&addr, &len);
ok(!ret, "got error %u\n", WSAGetLastError());
memset(buffer, 0xcc, sizeof(buffer));
--
2.30.2