Depending on reported winsock version.
Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- dlls/ws2_32/socket.c | 3 +-- dlls/ws2_32/tests/protocol.c | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/dlls/ws2_32/socket.c b/dlls/ws2_32/socket.c index 19a7d901414..7a1483f140f 100644 --- a/dlls/ws2_32/socket.c +++ b/dlls/ws2_32/socket.c @@ -419,7 +419,6 @@ static BOOL socket_list_remove( SOCKET socket ) return FALSE; }
-#define MAX_UDP_DATAGRAM 1024 static INT WINAPI WSA_DefaultBlockingHook( FARPROC x );
int num_startup; @@ -588,7 +587,7 @@ int WINAPI WSAStartup( WORD version, WSADATA *data ) strcpy( data->szDescription, "WinSock 2.0" ); strcpy( data->szSystemStatus, "Running" ); data->iMaxSockets = (LOBYTE(version) == 1 ? 32767 : 0); - data->iMaxUdpDg = MAX_UDP_DATAGRAM; + data->iMaxUdpDg = (LOBYTE(version) == 1 ? 65467 : 0); /* don't fill lpVendorInfo */ }
diff --git a/dlls/ws2_32/tests/protocol.c b/dlls/ws2_32/tests/protocol.c index a95b6e685af..8b429e5c914 100644 --- a/dlls/ws2_32/tests/protocol.c +++ b/dlls/ws2_32/tests/protocol.c @@ -2872,7 +2872,7 @@ static void test_startup(void) ok(!strcmp(data.szDescription, "WinSock 2.0"), "got description %s\n", debugstr_a(data.szDescription)); ok(!strcmp(data.szSystemStatus, "Running"), "got status %s\n", debugstr_a(data.szSystemStatus)); ok(data.iMaxSockets == (LOBYTE(tests[i].version) == 1 ? 32767 : 0), "got maximum sockets %u\n", data.iMaxSockets); - todo_wine ok(data.iMaxUdpDg == (LOBYTE(tests[i].version) == 1 ? 65467 : 0), "got maximum datagram size %u\n", data.iMaxUdpDg); + ok(data.iMaxUdpDg == (LOBYTE(tests[i].version) == 1 ? 65467 : 0), "got maximum datagram size %u\n", data.iMaxUdpDg);
WSASetLastError(0xdeadbeef); ret = WSACleanup();