Sync with trunk r43123
[reactos.git] / reactos / dll / win32 / ws2_32 / misc / stubs.c
index a5fe5a3..63f0f76 100644 (file)
@@ -30,7 +30,7 @@ getpeername(IN     SOCKET s,
         return SOCKET_ERROR;
     }
 
-    if (!ReferenceProviderByHandle((HANDLE)s, &Provider))
+    if (!ReferenceProviderByHandle((HANDLE)(ULONG_PTR)(s), &Provider))
     {
         WSASetLastError(WSAENOTSOCK);
         return SOCKET_ERROR;