[PATCH] ws2_32: Add stub for SIO_ENABLE_CIRCULAR_QUEUEING in WSAIoctl()
Julian Klemann
jklemann at codeweavers.com
Wed May 18 11:45:39 CDT 2022
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47233
Signed-off-by: Julian Klemann <jklemann at codeweavers.com>
---
dlls/ws2_32/socket.c | 12 ++++++++++++
dlls/ws2_32/tests/sock.c | 14 ++++++++++++++
2 files changed, 26 insertions(+)
diff --git a/dlls/ws2_32/socket.c b/dlls/ws2_32/socket.c
index 3d0c2deca35..88089fa8d74 100644
--- a/dlls/ws2_32/socket.c
+++ b/dlls/ws2_32/socket.c
@@ -2371,6 +2371,18 @@ INT WINAPI WSAIoctl(SOCKET s, DWORD code, LPVOID in_buff, DWORD in_size, LPVOID
return ret ? -1 : 0;
}
+ case SIO_ENABLE_CIRCULAR_QUEUEING:
+ {
+ NTSTATUS status = STATUS_SUCCESS;
+ DWORD ret;
+
+ FIXME( "SIO_ENABLE_CIRCULAR_QUEUEING stub\n" );
+ ret = server_ioctl_sock( s, IOCTL_AFD_WINE_COMPLETE_ASYNC, &status, sizeof(status),
+ NULL, 0, ret_size, overlapped, completion );
+ SetLastError( ret );
+ return ret ? -1 : 0;
+ }
+
case SIO_BASE_HANDLE:
{
NTSTATUS status;
diff --git a/dlls/ws2_32/tests/sock.c b/dlls/ws2_32/tests/sock.c
index f17ffba7a85..048b2b68ebb 100644
--- a/dlls/ws2_32/tests/sock.c
+++ b/dlls/ws2_32/tests/sock.c
@@ -5113,6 +5113,19 @@ static void test_base_handle(void)
}
}
+static void test_circular_queueing(void)
+{
+ SOCKET s;
+ DWORD size;
+ int ret;
+
+ s = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP);
+ ret = WSAIoctl(s, SIO_ENABLE_CIRCULAR_QUEUEING, NULL, 0, NULL, 0, &size, NULL, NULL);
+ ok(!ret, "expected 0, got %d\n", ret);
+
+ closesocket(s);
+}
+
static BOOL drain_pause = FALSE;
static DWORD WINAPI drain_socket_thread(LPVOID arg)
{
@@ -12578,6 +12591,7 @@ START_TEST( sock )
test_sioRoutingInterfaceQuery();
test_sioAddressListChange();
test_base_handle();
+ test_circular_queueing();
test_unsupported_ioctls();
test_WSASendMsg();
--
2.36.1
More information about the wine-devel
mailing list