Commit 4ada99aa authored by Austin English's avatar Austin English Committed by Alexandre Julliard

ws2_32: Add a stub for WSANSPIoctl.

parent 66e635ad
......@@ -6020,3 +6020,16 @@ INT WINAPI WSCWriteProviderOrder( LPDWORD entry, DWORD number )
FIXME("(%p 0x%08x) Stub!\n", entry, number);
return 0;
}
/***********************************************************************
* WSANSPIoctl (WS2_32.91)
*/
INT WINAPI WSANSPIoctl( HANDLE hLookup, DWORD dwControlCode, LPVOID lpvInBuffer,
DWORD cbInBuffer, LPVOID lpvOutBuffer, DWORD cbOutBuffer,
LPDWORD lpcbBytesReturned, LPWSACOMPLETION lpCompletion )
{
FIXME("(%p, 0x%08x, %p, 0x%08x, %p, 0x%08x, %p, %p) Stub!\n", hLookup, dwControlCode,
lpvInBuffer, cbInBuffer, lpvOutBuffer, cbOutBuffer, lpcbBytesReturned, lpCompletion);
WSASetLastError(WSA_NOT_ENOUGH_MEMORY);
return SOCKET_ERROR;
};
......@@ -85,7 +85,7 @@
@ stdcall WSALookupServiceEnd(long)
@ stdcall WSALookupServiceNextA(long long ptr ptr)
@ stdcall WSALookupServiceNextW(long long ptr ptr)
@ stub WSANSPIoctl
@ stdcall WSANSPIoctl(ptr long ptr long ptr long ptr ptr)
@ stdcall WSANtohl(long long ptr)
@ stdcall WSANtohs(long long ptr)
@ stdcall WSAProviderConfigChange(ptr ptr ptr)
......
......@@ -506,6 +506,37 @@ DECL_WINELIB_TYPE_AW(WSANAMESPACE_INFO)
DECL_WINELIB_TYPE_AW(PWSANAMESPACE_INFO)
DECL_WINELIB_TYPE_AW(LPWSANAMESPACE_INFO)
typedef enum _WSACOMPLETIONTYPE {
NSP_NOTIFY_IMMEDIATELY = 0,
NSP_NOTIFY_HWND = 1,
NSP_NOTIFY_EVENT = 2,
NSP_NOTIFY_PORT = 3,
NSP_NOTIFY_APC = 4
} WSACOMPLETIONTYPE, * PWSACOMPLETIONTYPE, * LPWSACOMPLETIONTYPE;
typedef struct _WSACOMPLETION {
WSACOMPLETIONTYPE Type;
union {
struct {
HWND hWnd;
UINT uMsg;
WPARAM context;
} WindowMessage;
struct {
LPWSAOVERLAPPED lpOverlapped;
} Event;
struct {
LPWSAOVERLAPPED lpOverlapped;
LPWSAOVERLAPPED_COMPLETION_ROUTINE lpfnCompletionProc;
} Apc;
struct {
LPWSAOVERLAPPED lpOverlapped;
HANDLE hPort;
ULONG_PTR Key;
} Port;
} Parameters;
} WSACOMPLETION, *PWSACOMPLETION, *LPWSACOMPLETION;
/*
* Winsock Function Typedefs
*
......@@ -613,6 +644,7 @@ 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 WSANSPIoctl(HANDLE,DWORD,LPVOID,DWORD,LPVOID,DWORD,LPDWORD,LPWSACOMPLETION);
int WINAPI WSANtohl(SOCKET,ULONG,ULONG*);
int WINAPI WSANtohs(SOCKET,WS(u_short),WS(u_short)*);
INT WINAPI WSAProviderConfigChange(LPHANDLE,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
......@@ -685,6 +717,7 @@ 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_WSANSPIoctl)(HANDLE, DWORD,LPVOID,DWORD,LPVOID,DWORD,LPDWORD,LPWSACOMPLETION);
typedef int (WINAPI *LPFN_WSANTOHL)(SOCKET,ULONG,ULONG*);
typedef int (WINAPI *LPFN_WSANTOHS)(SOCKET,WS(u_short),WS(u_short)*);
typedef INT (WINAPI *LPFN_WSAPROVIDERCONFIGCHANGE)(LPHANDLE,LPWSAOVERLAPPED,LPWSAOVERLAPPED_COMPLETION_ROUTINE);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment