[PATCH v2 1/3] winhttp: Fix filling TIMEVAL in netconn_create().

Paul Gofman pgofman at codeweavers.com
Mon Mar 14 05:31:26 CDT 2022


Signed-off-by: Paul Gofman <pgofman at codeweavers.com>
---
   Supersedes 229700: no changes, resent to avoid conflicts with the next patches.

 dlls/winhttp/net.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/winhttp/net.c b/dlls/winhttp/net.c
index 19fafb25804..09ed5e222d1 100644
--- a/dlls/winhttp/net.c
+++ b/dlls/winhttp/net.c
@@ -229,7 +229,7 @@ DWORD netconn_create( struct hostdata *host, const struct sockaddr_storage *sock
         if (ret == WSAEWOULDBLOCK || ret == WSAEINPROGRESS)
         {
             FD_SET set;
-            TIMEVAL timeval = { 0, timeout * 1000 };
+            TIMEVAL timeval = { timeout / 1000, (timeout % 1000) * 1000 };
             int res;
 
             FD_ZERO( &set );
-- 
2.35.1




More information about the wine-devel mailing list