Module: wine Branch: master Commit: 9d566032bbc40d6dfc4537d17a556facfa4d3440 URL: http://source.winehq.org/git/wine.git/?a=commit;h=9d566032bbc40d6dfc4537d17a...
Author: Paul Vriens paul.vriens.wine@gmail.com Date: Wed May 28 10:05:02 2008 +0200
ws2_32/tests: Fix crash on win98.
---
dlls/ws2_32/tests/sock.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/dlls/ws2_32/tests/sock.c b/dlls/ws2_32/tests/sock.c index 8aaa72f..8ee5c37 100644 --- a/dlls/ws2_32/tests/sock.c +++ b/dlls/ws2_32/tests/sock.c @@ -1123,6 +1123,10 @@ static void test_WSASocket(void) int ret, err; UINT pi_size;
+ /* Set pi_size explicitly to a value below 2*sizeof(WSAPROTOCOL_INFOA) + * to avoid a crash on win98. + */ + pi_size = 0; ret = WSAEnumProtocolsA(providers, NULL, &pi_size); ok(ret == SOCKET_ERROR, "WSAEnumProtocolsA({6,0}, NULL, 0) returned %d\n", ret);