mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2024-11-21 16:46:54 -08:00
Added patch to set return size when calling WSAIoctl with WS_SIO_GET_EXTENSION_FUNCTION_POINTER.
This commit is contained in:
parent
325f3758f8
commit
996d9ab307
@ -483,6 +483,7 @@ patch_enable_all ()
|
||||
enable_ws2_32_Tests="$1"
|
||||
enable_ws2_32_TransmitFile="$1"
|
||||
enable_ws2_32_WSACleanup="$1"
|
||||
enable_ws2_32_WSAIoctl="$1"
|
||||
enable_ws2_32_WriteWatches="$1"
|
||||
enable_ws2_32_getsockopt="$1"
|
||||
enable_wtsapi32_EnumerateProcesses="$1"
|
||||
@ -1700,6 +1701,9 @@ patch_enable ()
|
||||
ws2_32-WSACleanup)
|
||||
enable_ws2_32_WSACleanup="$2"
|
||||
;;
|
||||
ws2_32-WSAIoctl)
|
||||
enable_ws2_32_WSAIoctl="$2"
|
||||
;;
|
||||
ws2_32-WriteWatches)
|
||||
enable_ws2_32_WriteWatches="$2"
|
||||
;;
|
||||
@ -9853,6 +9857,21 @@ if test "$enable_ws2_32_WSACleanup" -eq 1; then
|
||||
) >> "$patchlist"
|
||||
fi
|
||||
|
||||
# Patchset ws2_32-WSAIoctl
|
||||
# |
|
||||
# | This patchset fixes the following Wine bugs:
|
||||
# | * [#43315] Set return size when calling WSAIoctl with WS_SIO_GET_EXTENSION_FUNCTION_POINTER
|
||||
# |
|
||||
# | Modified files:
|
||||
# | * dlls/ws2_32/socket.c, dlls/ws2_32/tests/sock.c
|
||||
# |
|
||||
if test "$enable_ws2_32_WSAIoctl" -eq 1; then
|
||||
patch_apply ws2_32-WSAIoctl/0001-ws2_32-Set-return-size-when-calling-WSAIoctl-with-WS.patch
|
||||
(
|
||||
printf '%s\n' '+ { "Kimmo Myllyvirta", "ws2_32: Set return size when calling WSAIoctl with WS_SIO_GET_EXTENSION_FUNCTION_POINTER.", 1 },';
|
||||
) >> "$patchlist"
|
||||
fi
|
||||
|
||||
# Patchset ws2_32-getsockopt
|
||||
# |
|
||||
# | This patchset fixes the following Wine bugs:
|
||||
|
@ -0,0 +1,47 @@
|
||||
From bc57f2c994179bbb3d0e8e2048b7b6011a84e3ab Mon Sep 17 00:00:00 2001
|
||||
From: Kimmo Myllyvirta <kimmo.myllyvirta@gmail.com>
|
||||
Date: Tue, 11 Jul 2017 11:42:06 +0200
|
||||
Subject: ws2_32: Set return size when calling WSAIoctl with
|
||||
WS_SIO_GET_EXTENSION_FUNCTION_POINTER.
|
||||
|
||||
---
|
||||
dlls/ws2_32/socket.c | 1 +
|
||||
dlls/ws2_32/tests/sock.c | 3 +++
|
||||
2 files changed, 4 insertions(+)
|
||||
|
||||
diff --git a/dlls/ws2_32/socket.c b/dlls/ws2_32/socket.c
|
||||
index 48d8f61553d..fac47d78527 100644
|
||||
--- a/dlls/ws2_32/socket.c
|
||||
+++ b/dlls/ws2_32/socket.c
|
||||
@@ -4985,6 +4985,7 @@ INT WINAPI WSAIoctl(SOCKET s, DWORD code, LPVOID in_buff, DWORD in_size, LPVOID
|
||||
{
|
||||
TRACE("-> got %s\n", guid_funcs[i].name);
|
||||
*(void **)out_buff = guid_funcs[i].func_ptr;
|
||||
+ total = sizeof(void *);
|
||||
break;
|
||||
}
|
||||
|
||||
diff --git a/dlls/ws2_32/tests/sock.c b/dlls/ws2_32/tests/sock.c
|
||||
index c66d0d9ccd9..91f2525c174 100644
|
||||
--- a/dlls/ws2_32/tests/sock.c
|
||||
+++ b/dlls/ws2_32/tests/sock.c
|
||||
@@ -7704,6 +7704,7 @@ static void test_ConnectEx(void)
|
||||
goto end;
|
||||
}
|
||||
|
||||
+ bytesReturned = 0xdeadbeef;
|
||||
iret = WSAIoctl(connector, SIO_GET_EXTENSION_FUNCTION_POINTER, &connectExGuid, sizeof(connectExGuid),
|
||||
&pConnectEx, sizeof(pConnectEx), &bytesReturned, NULL, NULL);
|
||||
if (iret) {
|
||||
@@ -7711,6 +7712,8 @@ static void test_ConnectEx(void)
|
||||
goto end;
|
||||
}
|
||||
|
||||
+ ok(bytesReturned == sizeof(pConnectEx), "expected sizeof(pConnectEx), got %u\n", bytesReturned);
|
||||
+
|
||||
bret = pConnectEx(INVALID_SOCKET, (struct sockaddr*)&address, addrlen, NULL, 0, &bytesReturned, &overlapped);
|
||||
ok(bret == FALSE && WSAGetLastError() == WSAENOTSOCK, "ConnectEx on invalid socket "
|
||||
"returned %d + errno %d\n", bret, WSAGetLastError());
|
||||
--
|
||||
2.13.1
|
||||
|
1
patches/ws2_32-WSAIoctl/definition
Normal file
1
patches/ws2_32-WSAIoctl/definition
Normal file
@ -0,0 +1 @@
|
||||
Fixes: [43315] Set return size when calling WSAIoctl with WS_SIO_GET_EXTENSION_FUNCTION_POINTER
|
Loading…
Reference in New Issue
Block a user