[PATCH] ws2_32: implemented SO_CONNECT_TIME stub

Marcus Meissner meissner at suse.de
Wed Jan 26 10:01:09 CST 2011


Hi,

Used by Eye-Fi software to check firewallsettings.

Ciao, Marcus
---
 dlls/ws2_32/socket.c |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/dlls/ws2_32/socket.c b/dlls/ws2_32/socket.c
index 774481d..d1a36ab 100644
--- a/dlls/ws2_32/socket.c
+++ b/dlls/ws2_32/socket.c
@@ -2536,6 +2536,19 @@ INT WINAPI WS_getsockopt(SOCKET s, INT level,
             return ret;
         }
 
+        case WS_SO_CONNECT_TIME: {
+            static int pretendtime = 0;
+
+            if (!pretendtime) FIXME("WS_SO_CONNECT_TIME - faking results\n");
+            if (!optlen || *optlen < sizeof(DWORD) || !optval)
+            {
+                SetLastError(WSAEFAULT);
+                return SOCKET_ERROR;
+            }
+            *(DWORD*)optval = pretendtime++;
+            *optlen = sizeof(DWORD);
+            return ret;
+        }
         /* As mentioned in setsockopt, Windows ignores this, so we
          * always return true here */
         case WS_SO_DONTROUTE:
-- 
1.7.1




More information about the wine-patches mailing list