Stub implementations for WPUCompleteOverlappedRequest,
WSADuplicateSocketW, WSAEnumNameSpaceProviders{A,W}, WSAGetQOSByName, WSAGetServiceClassInfo{A,W}, WSAGetServiceClassNameByClassId{A,W}, WSALookupServiceEnd, WSALookupServiceNext{A,W}, WSAProviderConfigChange, WSASetService{A,W}, WSCEnableNSProvider, WSCGetProviderPath, WSCInstallNameSpace, WSCWriteProviderOrder. Implementations for WSANtohl, WSANtohs, WSASocketA->W crosscall. Avoid NULL dereferences in WSAStringToAddress{A,W} and WSAAddressToString{A,W}.
This commit is contained in:
parent
07aa50bc48
commit
8be26da723
|
@ -760,3 +760,17 @@ INT WINAPI WSApSetPostRoutine(LPWPUPOSTMESSAGE lpPostRoutine)
|
|||
FIXME("(%p), stub !\n", lpPostRoutine);
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* (WS2_32.25)
|
||||
*/
|
||||
WSAEVENT WINAPI WPUCompleteOverlappedRequest(SOCKET s, LPWSAOVERLAPPED overlapped,
|
||||
DWORD error, DWORD transferred, LPINT errno)
|
||||
{
|
||||
FIXME("(0x%08x,%p,0x%08lx,0x%08lx,%p), stub !\n", s, overlapped, error, transferred, errno);
|
||||
|
||||
if (errno)
|
||||
*errno = WSAEINVAL;
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
@ -3018,11 +3018,40 @@ BOOL WINAPI WSACloseEvent(WSAEVENT event)
|
|||
SOCKET WINAPI WSASocketA(int af, int type, int protocol,
|
||||
LPWSAPROTOCOL_INFOA lpProtocolInfo,
|
||||
GROUP g, DWORD dwFlags)
|
||||
{
|
||||
INT len;
|
||||
WSAPROTOCOL_INFOW info;
|
||||
|
||||
TRACE("af=%d type=%d protocol=%d protocol_info=%p group=%d flags=0x%lx\n",
|
||||
af, type, protocol, lpProtocolInfo, g, dwFlags);
|
||||
|
||||
if (!lpProtocolInfo) return WSASocketW(af, type, protocol, NULL, g, dwFlags);
|
||||
|
||||
memcpy(&info, lpProtocolInfo, FIELD_OFFSET(WSAPROTOCOL_INFOW, szProtocol));
|
||||
len = MultiByteToWideChar(CP_ACP, 0, lpProtocolInfo->szProtocol, -1,
|
||||
info.szProtocol, WSAPROTOCOL_LEN * sizeof(WCHAR) + 1);
|
||||
|
||||
if (!len)
|
||||
{
|
||||
WSASetLastError( WSAEINVAL);
|
||||
return SOCKET_ERROR;
|
||||
}
|
||||
|
||||
return WSASocketW(af, type, protocol, &info, g, dwFlags);
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSASocketW (WS2_32.79)
|
||||
*
|
||||
*/
|
||||
SOCKET WINAPI WSASocketW(int af, int type, int protocol,
|
||||
LPWSAPROTOCOL_INFOW lpProtocolInfo,
|
||||
GROUP g, DWORD dwFlags)
|
||||
{
|
||||
SOCKET ret;
|
||||
|
||||
/*
|
||||
FIXME: The "advanced" parameters of WSASocketA (lpProtocolInfo,
|
||||
FIXME: The "advanced" parameters of WSASocketW (lpProtocolInfo,
|
||||
g, dwFlags except WSA_FLAG_OVERLAPPED) are ignored.
|
||||
*/
|
||||
|
||||
|
@ -3673,6 +3702,25 @@ int WINAPI WSADuplicateSocketA( SOCKET s, DWORD dwProcessId, LPWSAPROTOCOL_INFOA
|
|||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSADuplicateSocketW (WS2_32.33)
|
||||
*/
|
||||
int WINAPI WSADuplicateSocketW( SOCKET s, DWORD dwProcessId, LPWSAPROTOCOL_INFOW lpProtocolInfo )
|
||||
{
|
||||
HANDLE hProcess;
|
||||
|
||||
TRACE("(%d,%lx,%p)\n", s, dwProcessId, lpProtocolInfo);
|
||||
|
||||
memset(lpProtocolInfo, 0, sizeof(*lpProtocolInfo));
|
||||
hProcess = OpenProcess(PROCESS_DUP_HANDLE, FALSE, dwProcessId);
|
||||
DuplicateHandle(GetCurrentProcess(), SOCKET2HANDLE(s),
|
||||
hProcess, (LPHANDLE)&lpProtocolInfo->dwCatalogEntryId,
|
||||
0, FALSE, DUPLICATE_SAME_ACCESS);
|
||||
CloseHandle(hProcess);
|
||||
lpProtocolInfo->dwServiceFlags4 = 0xff00ff00; /* magic */
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSAInstallServiceClassA (WS2_32.48)
|
||||
*/
|
||||
|
@ -3716,8 +3764,10 @@ INT WINAPI WSAStringToAddressA(LPSTR AddressString,
|
|||
LONG inetaddr;
|
||||
LPSTR workBuffer=NULL,ptrPort;
|
||||
|
||||
TRACE( "(%s, %x, %p, %p, %d)\n", AddressString, AddressFamily, lpProtocolInfo,
|
||||
lpAddress, *lpAddressLength );
|
||||
TRACE( "(%s, %x, %p, %p, %p)\n", AddressString, AddressFamily, lpProtocolInfo,
|
||||
lpAddress, lpAddressLength );
|
||||
|
||||
if (!lpAddressLength || !lpAddress) return SOCKET_ERROR;
|
||||
|
||||
if (AddressString)
|
||||
{
|
||||
|
@ -3801,8 +3851,10 @@ INT WINAPI WSAStringToAddressW(LPWSTR AddressString,
|
|||
WSAPROTOCOL_INFOA infoA;
|
||||
LPWSAPROTOCOL_INFOA lpProtoInfoA = NULL;
|
||||
|
||||
TRACE( "(%s, %x, %p, %p, %d)\n", debugstr_w(AddressString), AddressFamily, lpProtocolInfo,
|
||||
lpAddress, *lpAddressLength );
|
||||
TRACE( "(%s, %x, %p, %p, %p)\n", debugstr_w(AddressString), AddressFamily, lpProtocolInfo,
|
||||
lpAddress, lpAddressLength );
|
||||
|
||||
if (!lpAddressLength || !lpAddress) return SOCKET_ERROR;
|
||||
|
||||
/* if ProtocolInfo is available - convert to ANSI variant */
|
||||
if (lpProtocolInfo)
|
||||
|
@ -3856,9 +3908,10 @@ INT WINAPI WSAAddressToStringA( LPSOCKADDR sockaddr, DWORD len,
|
|||
CHAR buffer[22]; /* 12 digits + 3 dots + ':' + 5 digits + '\0' */
|
||||
CHAR *p;
|
||||
|
||||
TRACE( "(%p, %lx, %p, %p, %ld)\n", sockaddr, len, info, string, *lenstr );
|
||||
TRACE( "(%p, %lx, %p, %p, %p)\n", sockaddr, len, info, string, lenstr );
|
||||
|
||||
if (!sockaddr || len < sizeof(SOCKADDR_IN)) return SOCKET_ERROR;
|
||||
if (!string || !lenstr) return SOCKET_ERROR;
|
||||
|
||||
/* sin_family is garanteed to be the first u_short */
|
||||
if (((SOCKADDR_IN *)sockaddr)->sin_family != AF_INET) return SOCKET_ERROR;
|
||||
|
@ -3916,9 +3969,10 @@ INT WINAPI WSAAddressToStringW( LPSOCKADDR sockaddr, DWORD len,
|
|||
static const WCHAR format[] = { '%','u','.','%','u','.','%','u','.','%','u',':','%','u',0 };
|
||||
WCHAR *p;
|
||||
|
||||
TRACE( "(%p, %lx, %p, %p, %ld)\n", sockaddr, len, info, string, *lenstr );
|
||||
TRACE( "(%p, %lx, %p, %p, %p)\n", sockaddr, len, info, string, lenstr );
|
||||
|
||||
if (!sockaddr || len < sizeof(SOCKADDR_IN)) return SOCKET_ERROR;
|
||||
if (!string || !lenstr) return SOCKET_ERROR;
|
||||
|
||||
/* sin_family is garanteed to be the first u_short */
|
||||
if (((SOCKADDR_IN *)sockaddr)->sin_family != AF_INET) return SOCKET_ERROR;
|
||||
|
@ -3945,6 +3999,77 @@ INT WINAPI WSAAddressToStringW( LPSOCKADDR sockaddr, DWORD len,
|
|||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSAEnumNameSpaceProvidersA (WS2_32.34)
|
||||
*/
|
||||
INT WINAPI WSAEnumNameSpaceProvidersA( LPDWORD len, LPWSANAMESPACE_INFOA buffer )
|
||||
{
|
||||
FIXME( "(%p %p) Stub!\n", len, buffer );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSAEnumNameSpaceProvidersW (WS2_32.35)
|
||||
*/
|
||||
INT WINAPI WSAEnumNameSpaceProvidersW( LPDWORD len, LPWSANAMESPACE_INFOW buffer )
|
||||
{
|
||||
FIXME( "(%p %p) Stub!\n", len, buffer );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSAGetQOSByName (WS2_32.41)
|
||||
*/
|
||||
BOOL WINAPI WSAGetQOSByName( SOCKET s, LPWSABUF lpQOSName, LPQOS lpQOS )
|
||||
{
|
||||
FIXME( "(0x%04x %p %p) Stub!\n", s, lpQOSName, lpQOS );
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSAGetServiceClassInfoA (WS2_32.42)
|
||||
*/
|
||||
INT WINAPI WSAGetServiceClassInfoA( LPGUID provider, LPGUID service, LPDWORD len,
|
||||
LPWSASERVICECLASSINFOA info )
|
||||
{
|
||||
FIXME( "(%s %s %p %p) Stub!\n", debugstr_guid(provider), debugstr_guid(service),
|
||||
len, info );
|
||||
WSASetLastError(WSA_NOT_ENOUGH_MEMORY);
|
||||
return SOCKET_ERROR;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSAGetServiceClassInfoW (WS2_32.43)
|
||||
*/
|
||||
INT WINAPI WSAGetServiceClassInfoW( LPGUID provider, LPGUID service, LPDWORD len,
|
||||
LPWSASERVICECLASSINFOW info )
|
||||
{
|
||||
FIXME( "(%s %s %p %p) Stub!\n", debugstr_guid(provider), debugstr_guid(service),
|
||||
len, info );
|
||||
WSASetLastError(WSA_NOT_ENOUGH_MEMORY);
|
||||
return SOCKET_ERROR;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSAGetServiceClassNameByClassIdA (WS2_32.44)
|
||||
*/
|
||||
INT WINAPI WSAGetServiceClassNameByClassIdA( LPGUID class, LPSTR service, LPDWORD len )
|
||||
{
|
||||
FIXME( "(%s %p %p) Stub!\n", debugstr_guid(class), service, len );
|
||||
WSASetLastError(WSA_NOT_ENOUGH_MEMORY);
|
||||
return SOCKET_ERROR;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSAGetServiceClassNameByClassIdW (WS2_32.45)
|
||||
*/
|
||||
INT WINAPI WSAGetServiceClassNameByClassIdW( LPGUID class, LPWSTR service, LPDWORD len )
|
||||
{
|
||||
FIXME( "(%s %p %p) Stub!\n", debugstr_guid(class), service, len );
|
||||
WSASetLastError(WSA_NOT_ENOUGH_MEMORY);
|
||||
return SOCKET_ERROR;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSALookupServiceBeginA (WS2_32.59)
|
||||
*/
|
||||
|
@ -3971,9 +4096,144 @@ INT WINAPI WSALookupServiceBeginW( LPWSAQUERYSETW lpqsRestrictions,
|
|||
return SOCKET_ERROR;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSALookupServiceBeginW (WS2_32.61)
|
||||
*/
|
||||
INT WINAPI WSALookupServiceEnd( HANDLE lookup )
|
||||
{
|
||||
FIXME("(%p) Stub!\n", lookup );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSALookupServiceNextA (WS2_32.62)
|
||||
*/
|
||||
INT WINAPI WSALookupServiceNextA( HANDLE lookup, DWORD flags, LPDWORD len, LPWSAQUERYSETA results )
|
||||
{
|
||||
FIXME( "(%p 0x%08lx %p %p) Stub!\n", lookup, flags, len, results );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSALookupServiceNextW (WS2_32.63)
|
||||
*/
|
||||
INT WINAPI WSALookupServiceNextW( HANDLE lookup, DWORD flags, LPDWORD len, LPWSAQUERYSETW results )
|
||||
{
|
||||
FIXME( "(%p 0x%08lx %p %p) Stub!\n", lookup, flags, len, results );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSANtohl (WS2_32.64)
|
||||
*/
|
||||
INT WINAPI WSANtohl( SOCKET s, u_long netlong, u_long* lphostlong )
|
||||
{
|
||||
TRACE( "(0x%04x 0x%08lx %p)\n", s, netlong, lphostlong );
|
||||
|
||||
if (!lphostlong) return WSAEFAULT;
|
||||
|
||||
*lphostlong = ntohl( netlong );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSANtohs (WS2_32.65)
|
||||
*/
|
||||
INT WINAPI WSANtohs( SOCKET s, u_short netshort, u_short* lphostshort )
|
||||
{
|
||||
TRACE( "(0x%04x 0x%08x %p)\n", s, netshort, lphostshort );
|
||||
|
||||
if (!lphostshort) return WSAEFAULT;
|
||||
|
||||
*lphostshort = ntohs( netshort );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSAProviderConfigChange (WS2_32.66)
|
||||
*/
|
||||
INT WINAPI WSAProviderConfigChange( LPHANDLE handle, LPWSAOVERLAPPED overlapped,
|
||||
LPWSAOVERLAPPED_COMPLETION_ROUTINE completion )
|
||||
{
|
||||
FIXME( "(%p %p %p) Stub!\n", handle, overlapped, completion );
|
||||
return SOCKET_ERROR;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSARecvDisconnect (WS2_32.68)
|
||||
*/
|
||||
INT WINAPI WSARecvDisconnect( SOCKET s, LPWSABUF disconnectdata )
|
||||
{
|
||||
TRACE( "(0x%04x %p)\n", s, disconnectdata );
|
||||
|
||||
return WS_shutdown( s, 0 );
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSASetServiceA (WS2_32.76)
|
||||
*/
|
||||
INT WINAPI WSASetServiceA( LPWSAQUERYSETA query, WSAESETSERVICEOP operation, DWORD flags )
|
||||
{
|
||||
FIXME( "(%p 0x%08x 0x%08lx) Stub!\n", query, operation, flags );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSASetServiceW (WS2_32.77)
|
||||
*/
|
||||
INT WINAPI WSASetServiceW( LPWSAQUERYSETW query, WSAESETSERVICEOP operation, DWORD flags )
|
||||
{
|
||||
FIXME( "(%p 0x%08x 0x%08lx) Stub!\n", query, operation, flags );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSCEnableNSProvider (WS2_32.84)
|
||||
*/
|
||||
INT WINAPI WSCEnableNSProvider( LPGUID provider, BOOL enable )
|
||||
{
|
||||
FIXME( "(%s 0x%08x) Stub!\n", debugstr_guid(provider), enable );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSCGetProviderPath (WS2_32.86)
|
||||
*/
|
||||
INT WINAPI WSCGetProviderPath( LPGUID provider, LPWSTR path, LPINT len, LPINT errno )
|
||||
{
|
||||
FIXME( "(%s %p %p %p) Stub!\n", debugstr_guid(provider), path, len, errno );
|
||||
|
||||
if (!errno || !provider || !len) return WSAEFAULT;
|
||||
|
||||
*errno = WSAEINVAL;
|
||||
return SOCKET_ERROR;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSCInstallNameSpace (WS2_32.87)
|
||||
*/
|
||||
INT WINAPI WSCInstallNameSpace( LPWSTR identifier, LPWSTR path, DWORD namespace,
|
||||
DWORD version, LPGUID provider )
|
||||
{
|
||||
FIXME( "(%s %s 0x%08lx 0x%08lx %s) Stub!\n", debugstr_w(identifier), debugstr_w(path),
|
||||
namespace, version, debugstr_guid(provider) );
|
||||
return 0;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSCUnInstallNameSpace (WS2_32.89)
|
||||
*/
|
||||
INT WINAPI WSCUnInstallNameSpace( LPGUID lpProviderId )
|
||||
{
|
||||
FIXME("(%p) Stub!\n", lpProviderId);
|
||||
|
||||
return NO_ERROR;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* WSCWriteProviderOrder (WS2_32.91)
|
||||
*/
|
||||
INT WINAPI WSCWriteProviderOrder( LPDWORD entry, DWORD number )
|
||||
{
|
||||
FIXME("(%p 0x%08lx) Stub!\n", entry, number);
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
22 stdcall shutdown(long long) WS_shutdown
|
||||
23 stdcall socket(long long long) WS_socket
|
||||
24 stdcall WSApSetPostRoutine(ptr)
|
||||
25 stub WPUCompleteOverlappedRequest
|
||||
25 stdcall WPUCompleteOverlappedRequest(long ptr long long ptr)
|
||||
26 stdcall WSAAccept(long ptr ptr ptr long)
|
||||
27 stdcall WSAAddressToStringA(ptr long ptr ptr ptr)
|
||||
28 stdcall WSAAddressToStringW(ptr long ptr ptr ptr)
|
||||
|
@ -34,19 +34,19 @@
|
|||
30 stdcall WSAConnect(long ptr long ptr ptr ptr ptr)
|
||||
31 stdcall WSACreateEvent ()
|
||||
32 stdcall WSADuplicateSocketA(long long ptr)
|
||||
33 stub WSADuplicateSocketW
|
||||
34 stub WSAEnumNameSpaceProvidersA
|
||||
35 stub WSAEnumNameSpaceProvidersW
|
||||
33 stdcall WSADuplicateSocketW(long long ptr)
|
||||
34 stdcall WSAEnumNameSpaceProvidersA(ptr ptr)
|
||||
35 stdcall WSAEnumNameSpaceProvidersW(ptr ptr)
|
||||
36 stdcall WSAEnumNetworkEvents(long long ptr)
|
||||
37 stdcall WSAEnumProtocolsA(ptr ptr ptr)
|
||||
38 stdcall WSAEnumProtocolsW(ptr ptr ptr)
|
||||
39 stdcall WSAEventSelect(long long long)
|
||||
40 stdcall WSAGetOverlappedResult(long ptr ptr long ptr)
|
||||
41 stub WSAGetQOSByName
|
||||
42 stub WSAGetServiceClassInfoA
|
||||
43 stub WSAGetServiceClassInfoW
|
||||
44 stub WSAGetServiceClassNameByClassIdA
|
||||
45 stub WSAGetServiceClassNameByClassIdW
|
||||
41 stdcall WSAGetQOSByName(long ptr ptr)
|
||||
42 stdcall WSAGetServiceClassInfoA(ptr ptr ptr ptr)
|
||||
43 stdcall WSAGetServiceClassInfoW(ptr ptr ptr ptr)
|
||||
44 stdcall WSAGetServiceClassNameByClassIdA(ptr ptr ptr)
|
||||
45 stdcall WSAGetServiceClassNameByClassIdW(ptr ptr ptr)
|
||||
46 stdcall WSAHtonl(long long ptr)
|
||||
47 stdcall WSAHtons(long long ptr)
|
||||
48 stdcall WSAInstallServiceClassA(ptr)
|
||||
|
@ -62,14 +62,14 @@
|
|||
58 stdcall WSAJoinLeaf(long ptr long ptr ptr ptr ptr long)
|
||||
59 stdcall WSALookupServiceBeginA(ptr long ptr)
|
||||
60 stdcall WSALookupServiceBeginW(ptr long ptr)
|
||||
61 stub WSALookupServiceEnd
|
||||
62 stub WSALookupServiceNextA
|
||||
63 stub WSALookupServiceNextW
|
||||
64 stub WSANtohl
|
||||
65 stub WSANtohs
|
||||
66 stub WSAProviderConfigChange
|
||||
61 stdcall WSALookupServiceEnd(long)
|
||||
62 stdcall WSALookupServiceNextA(long long ptr ptr)
|
||||
63 stdcall WSALookupServiceNextW(long long ptr ptr)
|
||||
64 stdcall WSANtohl(long long ptr)
|
||||
65 stdcall WSANtohs(long long ptr)
|
||||
66 stdcall WSAProviderConfigChange(ptr ptr ptr)
|
||||
67 stdcall WSARecv(long ptr long ptr ptr ptr ptr)
|
||||
68 stub WSARecvDisconnect
|
||||
68 stdcall WSARecvDisconnect(long ptr)
|
||||
69 stdcall WSARecvFrom(long ptr long ptr ptr ptr ptr ptr ptr )
|
||||
70 stdcall WSARemoveServiceClass(ptr)
|
||||
71 stdcall WSAResetEvent(long) kernel32.ResetEvent
|
||||
|
@ -77,22 +77,22 @@
|
|||
73 stdcall WSASendDisconnect(long ptr)
|
||||
74 stdcall WSASendTo(long ptr long ptr long ptr long ptr ptr)
|
||||
75 stdcall WSASetEvent(long) kernel32.SetEvent
|
||||
76 stub WSASetServiceA
|
||||
77 stub WSASetServiceW
|
||||
76 stdcall WSASetServiceA(ptr long long)
|
||||
77 stdcall WSASetServiceW(ptr long long)
|
||||
78 stdcall WSASocketA(long long long ptr long long)
|
||||
79 stub WSASocketW
|
||||
79 stdcall WSASocketW(long long long ptr long long)
|
||||
80 stdcall WSAStringToAddressA(str long ptr ptr ptr)
|
||||
81 stdcall WSAStringToAddressW(wstr long ptr ptr ptr)
|
||||
82 stdcall WSAWaitForMultipleEvents(long ptr long long long) kernel32.WaitForMultipleObjectsEx
|
||||
83 stdcall WSCDeinstallProvider(ptr ptr)
|
||||
84 stub WSCEnableNSProvider
|
||||
84 stdcall WSCEnableNSProvider(ptr long)
|
||||
85 stdcall WSCEnumProtocols(ptr ptr ptr ptr)
|
||||
86 stub WSCGetProviderPath
|
||||
87 stub WSCInstallNameSpace
|
||||
86 stdcall WSCGetProviderPath(ptr ptr ptr ptr)
|
||||
87 stdcall WSCInstallNameSpace(wstr wstr long long ptr)
|
||||
88 stdcall WSCInstallProvider(ptr wstr ptr long ptr)
|
||||
89 stdcall WSCUnInstallNameSpace(ptr)
|
||||
90 stub WSCWriteNameSpaceOrder
|
||||
91 stub WSCWriteProviderOrder
|
||||
91 stdcall WSCWriteProviderOrder(ptr long)
|
||||
|
||||
# 92 ~ 100 UNKNOWN
|
||||
|
||||
|
|
|
@ -465,6 +465,31 @@ DECL_WINELIB_TYPE_AW(WSAQUERYSET)
|
|||
DECL_WINELIB_TYPE_AW(PWSAQUERYSET)
|
||||
DECL_WINELIB_TYPE_AW(LPWSAQUERYSET)
|
||||
|
||||
typedef enum _WSAESETSERVICEOP {
|
||||
RNRSERVICE_REGISTER = 0,
|
||||
RNRSERVICE_DEREGISTER,
|
||||
RNRSERVICE_DELETE
|
||||
} WSAESETSERVICEOP, *PWSAESETSERVICEOP, *LPWSAESETSERVICEOP;
|
||||
|
||||
typedef struct _WSANAMESPACE_INFOA {
|
||||
GUID NSProviderId;
|
||||
DWORD dwNameSpace;
|
||||
BOOL fActive;
|
||||
DWORD dwVersion;
|
||||
LPSTR lpszIdentifier;
|
||||
} WSANAMESPACE_INFOA, *PWSANAMESPACE_INFOA, *LPWSANAMESPACE_INFOA;
|
||||
|
||||
typedef struct _WSANAMESPACE_INFOW {
|
||||
GUID NSProviderId;
|
||||
DWORD dwNameSpace;
|
||||
BOOL fActive;
|
||||
DWORD dwVersion;
|
||||
LPWSTR lpszIdentifier;
|
||||
} WSANAMESPACE_INFOW, *PWSANAMESPACE_INFOW, *LPWSANAMESPACE_INFOW;
|
||||
|
||||
DECL_WINELIB_TYPE_AW(WSANAMESPACE_INFO)
|
||||
DECL_WINELIB_TYPE_AW(PWSANAMESPACE_INFO)
|
||||
DECL_WINELIB_TYPE_AW(LPWSANAMESPACE_INFO)
|
||||
|
||||
/*
|
||||
* Winsock Function Typedefs
|
||||
|
@ -540,21 +565,25 @@ INT WINAPI WSAAddressToStringW(LPSOCKADDR,DWORD,LPWSAPROTOCOL_INFOW,LPWSTR,LPDWO
|
|||
BOOL WINAPI WSACloseEvent(WSAEVENT);
|
||||
int WINAPI WSAConnect(SOCKET,const struct WS(sockaddr)*,int,LPWSABUF,LPWSABUF,LPQOS,LPQOS);
|
||||
WSAEVENT WINAPI WSACreateEvent(void);
|
||||
/* WSADuplicateSocketA */
|
||||
/* WSADuplicateSocketW */
|
||||
/* WSAEnumNameSpaceProvidersA */
|
||||
/* WSAEnumNameSpaceProvidersW */
|
||||
INT WINAPI WSADuplicateSocketA(SOCKET,DWORD,LPWSAPROTOCOL_INFOA);
|
||||
INT WINAPI WSADuplicateSocketW(SOCKET,DWORD,LPWSAPROTOCOL_INFOW);
|
||||
#define WSADuplicateSocket WINELIB_NAME_AW(WSADuplicateSocket)
|
||||
INT WINAPI WSAEnumNameSpaceProvidersA(LPDWORD,LPWSANAMESPACE_INFOA);
|
||||
INT WINAPI WSAEnumNameSpaceProvidersW(LPDWORD,LPWSANAMESPACE_INFOW);
|
||||
#define WSAEnumNameSpaceProviders WINELIB_NAME_AW(WSAEnumNameSpaceProviders)
|
||||
int WINAPI WSAEnumNetworkEvents(SOCKET,WSAEVENT,LPWSANETWORKEVENTS);
|
||||
int WINAPI WSAEnumProtocolsA(LPINT,LPWSAPROTOCOL_INFOA,LPDWORD);
|
||||
int WINAPI WSAEnumProtocolsW(LPINT,LPWSAPROTOCOL_INFOW,LPDWORD);
|
||||
#define WSAEnumProtocols WINELIB_NAME_AW(WSAEnumProtocols)
|
||||
int WINAPI WSAEventSelect(SOCKET,WSAEVENT,long);
|
||||
BOOL WINAPI WSAGetOverlappedResult(SOCKET,LPWSAOVERLAPPED,LPDWORD,BOOL,LPDWORD);
|
||||
/* WSAGetQOSByName */
|
||||
/* WSAGetServiceClassInfoA */
|
||||
/* WSAGetServiceClassInfoW */
|
||||
/* WSAGetServiceClassNameByClassIdA */
|
||||
/* WSAGetServiceClassNameByClassIdW */
|
||||
BOOL WINAPI WSAGetQOSByName(SOCKET,LPWSABUF,LPQOS);
|
||||
INT WINAPI WSAGetServiceClassInfoA(LPGUID,LPGUID,LPDWORD,LPWSASERVICECLASSINFOA);
|
||||
INT WINAPI WSAGetServiceClassInfoW(LPGUID,LPGUID,LPDWORD,LPWSASERVICECLASSINFOW);
|
||||
#define WSAGetServiceClassInfo WINELIB_NAME_AW(WSAGetServiceClassInfo)
|
||||
INT WINAPI WSAGetServiceClassNameByClassIdA(LPGUID,LPSTR,LPDWORD);
|
||||
INT WINAPI WSAGetServiceClassNameByClassIdW(LPGUID,LPWSTR,LPDWORD);
|
||||
#define WSAGetServiceClassNameByClassId WINELIB_NAME_AW(WSAGetServiceClassNameByClassId)
|
||||
int WINAPI WSAHtonl(SOCKET,u_long,u_long*);
|
||||
int WINAPI WSAHtons(SOCKET,u_short,u_short*);
|
||||
int WINAPI WSAInstallServiceClassA(LPWSASERVICECLASSINFOA);
|
||||
|
@ -562,26 +591,28 @@ int WINAPI WSAInstallServiceClassW(LPWSASERVICECLASSINFOW);
|
|||
#define WSAInstallServiceClass WINELIB_NAME_AW(WSAInstallServiceClass)
|
||||
int WINAPI WSAIoctl(SOCKET,DWORD,LPVOID,DWORD,LPVOID,DWORD,LPDWORD,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
SOCKET WINAPI WSAJoinLeaf(SOCKET,const struct WS(sockaddr)*,int,LPWSABUF,LPWSABUF,LPQOS,LPQOS,DWORD);
|
||||
INT WINAPI WSALookupServiceBeginA( LPWSAQUERYSETA, DWORD, LPHANDLE);
|
||||
INT WINAPI WSALookupServiceBeginW( LPWSAQUERYSETW, DWORD, LPHANDLE);
|
||||
INT WINAPI WSALookupServiceBeginA(LPWSAQUERYSETA,DWORD,LPHANDLE);
|
||||
INT WINAPI WSALookupServiceBeginW(LPWSAQUERYSETW,DWORD,LPHANDLE);
|
||||
#define WSALookupServiceBegin WINELIB_NAME_AW(WSALookupServiceBegin)
|
||||
/* WSALookupServiceEnd */
|
||||
/* WSALookupServiceNextA */
|
||||
/* WSALookupServiceNextW */
|
||||
INT WINAPI WSALookupServiceEnd(HANDLE);
|
||||
INT WINAPI WSALookupServiceNextA(HANDLE,DWORD,LPDWORD,LPWSAQUERYSETA);
|
||||
INT WINAPI WSALookupServiceNextW(HANDLE,DWORD,LPDWORD,LPWSAQUERYSETW);
|
||||
#define WSALookupServiceNext WINELIB_NAME_AW(WSALookupServiceNext)
|
||||
int WINAPI WSANtohl(SOCKET,u_long,u_long*);
|
||||
int WINAPI WSANtohs(SOCKET,u_short,u_short*);
|
||||
/* WSAProviderConfigChange */
|
||||
INT WINAPI WSAProviderConfigChange(LPHANDLE,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
int WINAPI WSARecv(SOCKET,LPWSABUF,DWORD,LPDWORD,LPDWORD,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
int WINAPI WSARecvDisconnect(SOCKET,LPWSABUF);
|
||||
int WINAPI WSARecvFrom(SOCKET,LPWSABUF,DWORD,LPDWORD,LPDWORD,struct WS(sockaddr)*,LPINT,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
/* WSARemoveServiceClass */
|
||||
INT WINAPI WSARemoveServiceClass(LPGUID);
|
||||
BOOL WINAPI WSAResetEvent(WSAEVENT);
|
||||
int WINAPI WSASend(SOCKET,LPWSABUF,DWORD,LPDWORD,DWORD,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
int WINAPI WSASendDisconnect(SOCKET,LPWSABUF);
|
||||
int WINAPI WSASendTo(SOCKET,LPWSABUF,DWORD,LPDWORD,DWORD,const struct WS(sockaddr)*,int,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
BOOL WINAPI WSASetEvent(WSAEVENT);
|
||||
/* WSASetServiceA */
|
||||
/* WSASetServiceW */
|
||||
INT WINAPI WSASetServiceA(LPWSAQUERYSETA,WSAESETSERVICEOP,DWORD);
|
||||
INT WINAPI WSASetServiceW(LPWSAQUERYSETW,WSAESETSERVICEOP,DWORD);
|
||||
#define WSASetService WINELIB_NAME_AW(WSASetService)
|
||||
SOCKET WINAPI WSASocketA(int,int,int,LPWSAPROTOCOL_INFOA,GROUP,DWORD);
|
||||
SOCKET WINAPI WSASocketW(int,int,int,LPWSAPROTOCOL_INFOW,GROUP,DWORD);
|
||||
#define WSASocket WINELIB_NAME_AW(WSASocket)
|
||||
|
@ -607,46 +638,53 @@ typedef INT (WINAPI *LPFN_WSAADRESSTOSTRINGW)(LPSOCKADDR,DWORD,LPWSAPROTOCOL_INF
|
|||
typedef BOOL (WINAPI *LPFN_WSACLOSEEVENT)(WSAEVENT);
|
||||
typedef int (WINAPI *LPFN_WSACONNECT)(SOCKET,const struct WS(sockaddr)*,int,LPWSABUF,LPWSABUF,LPQOS,LPQOS);
|
||||
typedef WSAEVENT (WINAPI *LPFN_WSACREATEEVENT)(void);
|
||||
/* WSADuplicateSocketA */
|
||||
/* WSADuplicateSocketW */
|
||||
/* WSAEnumNameSpaceProvidersA */
|
||||
/* WSAEnumNameSpaceProvidersW */
|
||||
typedef INT (WINAPI *LPFN_WSADUPLICATESOCKETA)(SOCKET,DWORD,LPWSAPROTOCOL_INFOA);
|
||||
typedef INT (WINAPI *LPFN_WSADUPLICATESOCKETW)(SOCKET,DWORD,LPWSAPROTOCOL_INFOW);
|
||||
#define LPFN_WSADUPLICATESOCKET WINELIB_NAME_AW(LPFN_WSADUPLICATESOCKET)
|
||||
typedef INT (WINAPI *LPFNWSAENUMNAMESPACEPROVIDERSA)(LPDWORD,LPWSANAMESPACE_INFOA);
|
||||
typedef INT (WINAPI *LPFNWSAENUMNAMESPACEPROVIDERSW)(LPDWORD,LPWSANAMESPACE_INFOW);
|
||||
#define LPFN_WSAENUMNAMESPACEPROVIDERS WINELIB_NAME_AW(LPFNWSAENUMNAMESPACEPROVIDERS)
|
||||
typedef int (WINAPI *LPFN_WSAENUMNETWORKEVENT)(SOCKET,WSAEVENT,LPWSANETWORKEVENTS);
|
||||
typedef int (WINAPI *LPFN_WSAENUMPROTOCOLSA)(LPINT,LPWSAPROTOCOL_INFOA,LPDWORD);
|
||||
typedef int (WINAPI *LPFN_WSAENUMPROTOCOLSW)(LPINT,LPWSAPROTOCOL_INFOW,LPDWORD);
|
||||
#define LPFN_WSAENUMPROTOCOLS WINELIB_NAME_AW(LPFN_WSAENUMPROTOCOLS)
|
||||
typedef int (WINAPI *LPFN_WSAEVENTSELECT)(SOCKET,WSAEVENT,long);
|
||||
typedef BOOL (WINAPI *LPFN_WSAGETOVERLAPPEDRESULT)(SOCKET,LPWSAOVERLAPPED,LPDWORD,BOOL,LPDWORD);
|
||||
/* WSAGetQOSByName */
|
||||
/* WSAGetServiceClassInfoA */
|
||||
/* WSAGetServiceClassInfoW */
|
||||
/* WSAGetServiceClassNameByClassIdA */
|
||||
/* WSAGetServiceClassNameByClassIdW */
|
||||
typedef BOOL (WINAPI *LPFNWSAGETQOSBYNAME)(SOCKET,LPWSABUF,LPQOS);
|
||||
typedef INT (WINAPI *LPFNWSAGETSERVICECLASSINFOA)(LPGUID,LPGUID,LPDWORD,LPWSASERVICECLASSINFOA);
|
||||
typedef INT (WINAPI *LPFNWSAGETSERVICECLASSINFOW)(LPGUID,LPGUID,LPDWORD,LPWSASERVICECLASSINFOW);
|
||||
#define LPFN_LPFNWSAGETSERVICECLASSINFO WINELIB_NAME_AW(LPFN_LPFNWSAGETSERVICECLASSINFO)
|
||||
typedef INT (WINAPI *LPFN_WSAGETSERVICECLASSNAMEBYCLASSIDA)(LPGUID,LPSTR,LPDWORD);
|
||||
typedef INT (WINAPI *LPFN_WSAGETSERVICECLASSNAMEBYCLASSIDW)(LPGUID,LPWSTR,LPDWORD);
|
||||
#define LPFN_WSAGETSERVICECLASSNAMEBYCLASSID WINELIB_NAME_AW(LPFN_WSAGETSERVICECLASSNAMEBYCLASSID)
|
||||
typedef int (WINAPI *LPFN_WSAHTONL)(SOCKET,u_long,u_long*);
|
||||
typedef int (WINAPI *LPFN_WSAHTONS)(SOCKET,u_short,u_short*);
|
||||
typedef int (WINAPI LPFN_WSAINSTALLSERVICECLASSA)(LPWSASERVICECLASSINFOA);
|
||||
typedef int (WINAPI LPFN_WSAINSTALLSERVICECLASSW)(LPWSASERVICECLASSINFOW);
|
||||
typedef int (WINAPI *LPFN_WSAIOCTL)(SOCKET,DWORD,LPVOID,DWORD,LPVOID,DWORD,LPDWORD,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
typedef int (WINAPI *LPFN_WSAJOINLEAF)(SOCKET,const struct WS(sockaddr)*,int,LPWSABUF,LPWSABUF,LPQOS,LPQOS,DWORD);
|
||||
/* WSALookupServiceBeginA */
|
||||
/* WSALookupServiceBeginW */
|
||||
/* WSALookupServiceEnd */
|
||||
/* WSALookupServiceNextA */
|
||||
/* WSALookupServiceNextW */
|
||||
typedef INT (WINAPI *LPFN_WSALOOKUPSERVICEBEGINA)(LPWSAQUERYSETA,DWORD,LPHANDLE);
|
||||
typedef INT (WINAPI *LPFN_WSALOOKUPSERVICEBEGINW)(LPWSAQUERYSETW,DWORD,LPHANDLE);
|
||||
#define LPFN_WSALOOKUPSERVICEBEGIN WINELIB_NAME_AW(LPFN_WSALOOKUPSERVICEBEGIN);
|
||||
typedef INT (WINAPI *LPFN_WSALOOKUPSERVICEEND(HANDLE);
|
||||
typedef INT (WINAPI *LPFN_WSALOOKUPSERVICENEXTA)(HANDLE,DWORD,LPDWORD,LPWSAQUERYSETA);
|
||||
typedef INT (WINAPI *LPFN_WSALOOKUPSERVICENEXTW)(HANDLE,DWORD,LPDWORD,LPWSAQUERYSETW);
|
||||
#define LPFN_WSALOOKUPSERVICENEXT WINELIB_NAME_AW(LPFN_WSALOOKUPSERVICENEXT)
|
||||
typedef int (WINAPI *LPFN_WSANTOHL)(SOCKET,u_long,u_long*);
|
||||
typedef int (WINAPI *LPFN_WSANTOHS)(SOCKET,u_short,u_short*);
|
||||
/* WSAProviderConfigChange */
|
||||
typedef INT (WINAPI *LPFN_WSAPROVIDERCONFIGCHANGE)(LPHANDLE,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
typedef int (WINAPI *LPFN_WSARECV)(SOCKET,LPWSABUF,DWORD,LPDWORD,LPDWORD,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
typedef int (WINAPI *LPFN_WSARECVDISCONNECT)(SOCKET,LPWSABUF);
|
||||
typedef int (WINAPI *LPFN_WSARECVFROM)(SOCKET,LPWSABUF,DWORD,LPDWORD,LPDWORD,struct WS(sockaddr)*,LPINT,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
/* WSARemoveServiceClass */
|
||||
typedef INT (WINAPI *LPFN_WSAREMOVESERVICECLASS)(LPGUID);
|
||||
typedef BOOL (WINAPI *LPFN_WSARESETEVENT)(WSAEVENT);
|
||||
typedef int (WINAPI *LPFN_WSASEND)(SOCKET,LPWSABUF,DWORD,LPDWORD,DWORD,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
typedef int (WINAPI *LPFN_WSASENDDISCONNECT)(SOCKET,LPWSABUF);
|
||||
typedef int (WINAPI *LPFN_WSASENDTO)(SOCKET,LPWSABUF,DWORD,LPDWORD,DWORD,const struct WS(sockaddr)*,int,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
|
||||
typedef BOOL (WINAPI *LPFN_WSASETEVENT)(WSAEVENT);
|
||||
/* WSASetServiceA */
|
||||
/* WSASetServiceW */
|
||||
typedef INT (WINAPI *LPFN_WSASETSERVICEA)(LPWSAQUERYSETA,WSAESETSERVICEOP,DWORD);
|
||||
typedef INT (WINAPI *LPFN_WSASETSERVICEW)(LPWSAQUERYSETW,WSAESETSERVICEOP,DWORD);
|
||||
#define LPFN_WSASETSERVICE WINELIB_NAME_AW(LPFN_WSASETSERVICE)
|
||||
typedef SOCKET (WINAPI *LPFN_WSASOCKETA)(int,int,int,LPWSAPROTOCOL_INFOA,GROUP,DWORD);
|
||||
typedef SOCKET (WINAPI *LPFN_WSASOCKETW)(int,int,int,LPWSAPROTOCOL_INFOW,GROUP,DWORD);
|
||||
typedef INT (WINAPI *LPFN_WSASTRINGTOADDRESSA)(LPSTR,INT,LPWSAPROTOCOL_INFOA,LPSOCKADDR,LPINT);
|
||||
|
|
Loading…
Reference in New Issue