WXWORK passes 300 seconds, which overflows 32-bit multiplication.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52383 Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- dlls/ws2_32/socket.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/ws2_32/socket.c b/dlls/ws2_32/socket.c index f0c8f4a72d0..87fa3629b1c 100644 --- a/dlls/ws2_32/socket.c +++ b/dlls/ws2_32/socket.c @@ -2409,7 +2409,7 @@ int WINAPI select( int count, fd_set *read_ptr, fd_set *write_ptr, }
if (timeout) - params->timeout = timeout->tv_sec * -10000000 + timeout->tv_usec * -10; + params->timeout = (LONGLONG)timeout->tv_sec * -10000000 + (LONGLONG)timeout->tv_usec * -10; else params->timeout = TIMEOUT_INFINITE;
This is not particularly likely to overflow, but there is no harm in being careful.
Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- dlls/ws2_32/socket.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/ws2_32/socket.c b/dlls/ws2_32/socket.c index 87fa3629b1c..e43d6c5d671 100644 --- a/dlls/ws2_32/socket.c +++ b/dlls/ws2_32/socket.c @@ -2574,7 +2574,7 @@ int WINAPI WSAPoll( WSAPOLLFD *fds, ULONG count, int timeout ) return SOCKET_ERROR; }
- params->timeout = (timeout >= 0 ? timeout * -10000 : TIMEOUT_INFINITE); + params->timeout = (timeout >= 0 ? (LONGLONG)timeout * -10000 : TIMEOUT_INFINITE);
for (i = 0; i < count; ++i) {
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=105250
Your paranoid android.
=== debian11 (32 bit Chinese:China report) ===
ws2_32: sock.c:1135: Test failed: wait failed, error 258 sock.c:1135: Test failed: wait failed, error 258
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=105249
Your paranoid android.
=== debian11 (64 bit WoW report) ===
ws2_32: protocol.c:2020: Test failed: wait failed protocol.c:2022: Test failed: overlapped result is 10036 protocol.c:2024: Test failed: overlapped.Internal = 2734 protocol.c:2026: Test failed: got 0