Victor Pelt wrote:

@@ -2447,7 +2485,18 @@ BOOL WINAPI InternetSetOptionW(HINTERNET
        TRACE("Option INTERNET_OPTION_DISABLE_PASSPORT_AUTH: harmless stub, since 
not enabled\n");
        break;
    case INTERNET_OPTION_RECEIVE_TIMEOUT:
-        FIXME("Option INTERNET_OPTION_RECEIVE_TIMEOUT: STUB\n");
+      {
+       unsigned long conns=*(unsigned long*)lpBuffer;
+       /* have HINTERNET hInternet , handle where to set the options */
+       int result = setsockopt(INET_getSocketHelper(lpwhh), 
INET_getProtocolHelper(lpwhh), SO_RCVTIMEO, lpBuffer, (int)sizeof(lpBuffer));
+
+       if (result == 0) {
+         ret = TRUE;
+        } else {
+         /* Translate the result in the right error to return */
+         ret = FALSE;
+        }
+      }

It would be much better to implement this in netconnection.c. Perhaps calling it something like NETCONNECTION_set_timeout and allow both the send and receive timeouts to be set with it.

--
Rob Shearman



Reply via email to