Separated Win16 (USER) and Win32 (MPR) network routines.

Moved implementation of MPR to dlls/mpr/.
Added proper headers and stubs for missing MPR routines.
This commit is contained in:
Ulrich Weigand 1999-08-07 14:32:33 +00:00 committed by Alexandre Julliard
parent d4b13da309
commit bb1984e6bd
22 changed files with 2149 additions and 1099 deletions

View File

@ -39,6 +39,7 @@ LIBSUBDIRS = \
dlls/imagehlp \
dlls/imm32 \
dlls/lzexpand \
dlls/mpr \
dlls/msacm \
dlls/msacm32 \
dlls/msnet32 \
@ -130,6 +131,7 @@ LIBOBJS = \
dlls/imagehlp/imagehlp.o \
dlls/imm32/imm32.o \
dlls/lzexpand/lzexpand.o \
dlls/mpr/mpr.o \
dlls/msacm/msacm.o \
dlls/msacm32/msacm32.o \
dlls/msnet32/msnet32.o \

2
configure vendored
View File

@ -5473,6 +5473,7 @@ dlls/dciman32/Makefile
dlls/imagehlp/Makefile
dlls/imm32/Makefile
dlls/lzexpand/Makefile
dlls/mpr/Makefile
dlls/msacm/Makefile
dlls/msacm32/Makefile
dlls/msnet32/Makefile
@ -5659,6 +5660,7 @@ dlls/dciman32/Makefile
dlls/imagehlp/Makefile
dlls/imm32/Makefile
dlls/lzexpand/Makefile
dlls/mpr/Makefile
dlls/msacm/Makefile
dlls/msacm32/Makefile
dlls/msnet32/Makefile

View File

@ -802,6 +802,7 @@ dlls/dciman32/Makefile
dlls/imagehlp/Makefile
dlls/imm32/Makefile
dlls/lzexpand/Makefile
dlls/mpr/Makefile
dlls/msacm/Makefile
dlls/msacm32/Makefile
dlls/msnet32/Makefile

View File

@ -8,6 +8,7 @@ SUBDIRS = \
imagehlp \
imm32 \
lzexpand \
mpr \
msacm \
msacm32 \
msnet32 \

2
dlls/mpr/.cvsignore Normal file
View File

@ -0,0 +1,2 @@
Makefile
mpr.spec.c

23
dlls/mpr/Makefile.in Normal file
View File

@ -0,0 +1,23 @@
DEFS = @DLLFLAGS@ -D__WINE__
TOPSRCDIR = @top_srcdir@
TOPOBJDIR = ../..
SRCDIR = @srcdir@
VPATH = @srcdir@
MODULE = mpr
SPEC_SRCS = mpr.spec
C_SRCS = \
auth.c \
mpr_main.c \
multinet.c \
nps.c \
pwcache.c \
wnet.c
all: $(MODULE).o
@MAKE_RULES@
### Dependencies:

77
dlls/mpr/auth.c Normal file
View File

@ -0,0 +1,77 @@
/*
* MPR Authentication and Logon functions
*/
#include "winbase.h"
#include "winnetwk.h"
#include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(mpr)
/*****************************************************************
* WNetLogoffA [MPR.89]
*/
DWORD WINAPI WNetLogoffA( LPCSTR lpProvider, HWND hwndOwner )
{
FIXME( "(%s, %04x): stub\n", debugstr_a(lpProvider), hwndOwner );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetLogoffW [MPR.90]
*/
DWORD WINAPI WNetLogoffW( LPCWSTR lpProvider, HWND hwndOwner )
{
FIXME( "(%s, %04x): stub\n", debugstr_w(lpProvider), hwndOwner );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetLogonA [MPR.91]
*/
DWORD WINAPI WNetLogonA( LPCSTR lpProvider, HWND hwndOwner )
{
FIXME( "(%s, %04x): stub\n", debugstr_a(lpProvider), hwndOwner );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetLogonW [MPR.91]
*/
DWORD WINAPI WNetLogonW( LPCWSTR lpProvider, HWND hwndOwner )
{
FIXME( "(%s, %04x): stub\n", debugstr_w(lpProvider), hwndOwner );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetVerifyPasswordA [MPR.91]
*/
DWORD WINAPI WNetVerifyPasswordA( LPCSTR lpszPassword, BOOL *pfMatch )
{
FIXME( "(%p, %p): stub\n", lpszPassword, pfMatch );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetVerifyPasswordW [MPR.91]
*/
DWORD WINAPI WNetVerifyPasswordW( LPCWSTR lpszPassword, BOOL *pfMatch )
{
FIXME( "(%p, %p): stub\n", lpszPassword, pfMatch );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}

View File

@ -27,20 +27,20 @@ type win32
0024 stdcall MPR_Free(ptr) MPR_Free
0025 stdcall MPR_25(ptr long) _MPR_25
0026 stdcall MultinetGetConnectionPerformanceA(ptr ptr) MultinetGetConnectionPerformanceA
0027 stub MultinetGetConnectionPerformanceW
0027 stdcall MultinetGetConnectionPerformanceW(ptr ptr) MultinetGetConnectionPerformanceW
0028 stdcall MultinetGetErrorTextA(long ptr long)MultinetGetErrorTextA
0029 stdcall MultinetGetErrorTextW(long ptr long)MultinetGetErrorTextW
0030 stub NPSAuthenticationDialogA
0031 stub NPSCopyStringA
0032 stub NPSDeviceGetNumberA
0033 stub NPSDeviceGetStringA
0034 stdcall NPSGetProviderHandleA(long) NPSGetProviderHandleA
0030 stdcall NPSAuthenticationDialogA(ptr) NPSAuthenticationDialogA
0031 stdcall NPSCopyStringA(str ptr ptr) NPSCopyStringA
0032 stdcall NPSDeviceGetNumberA(str ptr ptr) NPSDeviceGetNumberA
0033 stdcall NPSDeviceGetStringA(long long ptr long) NPSDeviceGetStringA
0034 stdcall NPSGetProviderHandleA(ptr) NPSGetProviderHandleA
0035 stdcall NPSGetProviderNameA(long ptr) NPSGetProviderNameA
0036 stdcall NPSGetSectionNameA(long ptr) NPSGetSectionNameA
0037 stub NPSNotifyGetContextA
0038 stub NPSNotifyRegisterA
0039 stub NPSSetCustomTextA
0040 stub NPSSetExtendedErrorA
0037 stdcall NPSNotifyGetContextA(ptr) NPSNotifyGetContextA
0038 stdcall NPSNotifyRegisterA(long ptr) NPSNotifyRegisterA
0039 stdcall NPSSetCustomTextA(str) NPSSetCustomTextA
0040 stdcall NPSSetExtendedErrorA(long str) NPSSetExtendedErrorA
0041 stub PwdChangePasswordA
0042 stub PwdChangePasswordW
0043 stub PwdGetPasswordStatusA
@ -58,16 +58,16 @@ type win32
0055 stdcall WNetCancelConnection2W(wstr long long) WNetCancelConnection2W
0056 stdcall WNetCancelConnectionA(str long) WNetCancelConnectionA
0057 stdcall WNetCancelConnectionW(wstr long) WNetCancelConnectionW
0058 stub WNetCloseEnum
0058 stdcall WNetCloseEnum(long) WNetCloseEnum
0059 stdcall WNetConnectionDialog1A(ptr) WNetConnectionDialog1A
0060 stdcall WNetConnectionDialog1W(ptr) WNetConnectionDialog1W
0061 stdcall WNetConnectionDialog(long long) WNetConnectionDialog
0062 stub WNetDisconnectDialog1A
0063 stub WNetDisconnectDialog1W
0064 stub WNetDisconnectDialog
0062 stdcall WNetDisconnectDialog1A(ptr) WNetDisconnectDialog1A
0063 stdcall WNetDisconnectDialog1W(ptr) WNetDisconnectDialog1W
0064 stdcall WNetDisconnectDialog(long long) WNetDisconnectDialog
0065 stdcall WNetEnumCachedPasswords(str long long ptr) WNetEnumCachedPasswords
0066 stub WNetEnumResourceA
0067 stub WNetEnumResourceW
0066 stdcall WNetEnumResourceA(long ptr ptr ptr) WNetEnumResourceA
0067 stdcall WNetEnumResourceW(long ptr ptr ptr) WNetEnumResourceW
0068 stub WNetFormatNetworkNameA
0069 stub WNetFormatNetworkNameW
0070 stdcall WNetGetCachedPassword(ptr long ptr ptr long) WNetGetCachedPassword
@ -75,35 +75,35 @@ type win32
0072 stdcall WNetGetConnectionW(wstr ptr ptr) WNetGetConnectionW
0073 stub WNetGetHomeDirectoryA
0074 stub WNetGetHomeDirectoryW
0075 stub WNetGetLastErrorA
0076 stub WNetGetLastErrorW
0077 stub WNetGetNetworkInformationA
0078 stub WNetGetNetworkInformationW
0075 stdcall WNetGetLastErrorA(ptr ptr long ptr long) WNetGetLastErrorA
0076 stdcall WNetGetLastErrorW(ptr ptr long ptr long) WNetGetLastErrorW
0077 stdcall WNetGetNetworkInformationA(str ptr) WNetGetNetworkInformationA
0078 stdcall WNetGetNetworkInformationW(wstr ptr) WNetGetNetworkInformationW
0079 stdcall WNetGetProviderNameA(long ptr ptr) WNetGetProviderNameA
0080 stdcall WNetGetProviderNameW(long ptr ptr) WNetGetProviderNameW
0081 stdcall WNetGetResourceInformationA(ptr ptr ptr ptr) WNetGetResourceInformationA
0082 stub WNetGetResourceInformationW
0083 stub WNetGetResourceParentA
0084 stub WNetGetResourceParentW
0082 stdcall WNetGetResourceInformationW(ptr ptr ptr ptr) WNetGetResourceInformationW
0083 stdcall WNetGetResourceParentA(ptr ptr ptr) WNetGetResourceParentA
0084 stdcall WNetGetResourceParentW(ptr ptr ptr) WNetGetResourceParentW
0085 stdcall WNetGetUniversalNameA (str long ptr ptr) WNetGetUniversalNameA
0086 stdcall WNetGetUniversalNameW (wstr long ptr ptr) WNetGetUniversalNameW
0087 stdcall WNetGetUserA(str ptr ptr) WNetGetUserA
0088 stdcall WNetGetUserW(wstr wstr ptr) WNetGetUserW
0089 stub WNetLogoffA
0090 stub WNetLogoffW
0091 stub WNetLogonA
0092 stub WNetLogonW
0089 stdcall WNetLogoffA(str long) WNetLogoffA
0090 stdcall WNetLogoffW(wstr long) WNetLogoffW
0091 stdcall WNetLogonA(str long) WNetLogonA
0092 stdcall WNetLogonW(wstr long) WNetLogonW
0093 stdcall WNetOpenEnumA(long long long ptr ptr) WNetOpenEnumA
0094 stdcall WNetOpenEnumW(long long long ptr ptr) WNetOpenEnumW
0095 stdcall WNetRemoveCachedPassword(long long long) WNetRemoveCachedPassword
0096 stub WNetRestoreConnectionA
0097 stub WNetRestoreConnectionW
0098 stub WNetSetConnectionA
0099 stub WNetSetConnectionW
0096 stdcall WNetRestoreConnectionA(long str) WNetRestoreConnectionA
0097 stdcall WNetRestoreConnectionW(long wstr) WNetRestoreConnectionW
0098 stdcall WNetSetConnectionA(str long ptr) WNetSetConnectionA
0099 stdcall WNetSetConnectionW(wstr long ptr) WNetSetConnectionW
0100 stdcall WNetUseConnectionA(long ptr str str long str ptr ptr) WNetUseConnectionA
0101 stdcall WNetUseConnectionW(long ptr wstr wstr long wstr ptr ptr) WNetUseConnectionW
0102 stub WNetVerifyPasswordA
0103 stub WNetVerifyPasswordW
0102 stdcall WNetVerifyPasswordA(str ptr) WNetVerifyPasswordA
0103 stdcall WNetVerifyPasswordW(wstr ptr) WNetVerifyPasswordW
#additions, not in win95 mpr.dll
0104 stub WNetRestoreConnection

55
dlls/mpr/mpr_main.c Normal file
View File

@ -0,0 +1,55 @@
/*
* MPR undocumented functions
*/
#include "winbase.h"
#include "winnetwk.h"
#include "heap.h"
#include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(mpr)
/*
* FIXME: The following routines should use a private heap ...
*/
/*****************************************************************
* MPR_Alloc [MPR.22]
*/
LPVOID WINAPI MPR_Alloc( DWORD dwSize )
{
return HeapAlloc( SystemHeap, HEAP_ZERO_MEMORY, dwSize );
}
/*****************************************************************
* MPR_ReAlloc [MPR.23]
*/
LPVOID WINAPI MPR_ReAlloc( LPVOID lpSrc, DWORD dwSize )
{
if ( lpSrc )
return HeapReAlloc( SystemHeap, HEAP_ZERO_MEMORY, lpSrc, dwSize );
else
return HeapAlloc( SystemHeap, HEAP_ZERO_MEMORY, dwSize );
}
/*****************************************************************
* MPR_Free [MPR.24]
*/
BOOL WINAPI MPR_Free( LPVOID lpMem )
{
if ( lpMem )
return HeapFree( SystemHeap, 0, lpMem );
else
return FALSE;
}
/*****************************************************************
* [MPR.25]
*/
BOOL WINAPI _MPR_25( LPBYTE lpMem, INT len )
{
FIXME( "(%p, %d): stub\n", lpMem, len );
return FALSE;
}

62
dlls/mpr/multinet.c Normal file
View File

@ -0,0 +1,62 @@
/*
* MPR Multinet functions
*/
#include "winbase.h"
#include "winnetwk.h"
#include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(mpr)
/*****************************************************************
* MultinetGetConnectionPerformanceA [MPR.25]
*
* RETURNS
* Success: NO_ERROR
* Failure: ERROR_NOT_SUPPORTED, ERROR_NOT_CONNECTED,
* ERROR_NO_NET_OR_BAD_PATH, ERROR_BAD_DEVICE,
* ERROR_BAD_NET_NAME, ERROR_INVALID_PARAMETER,
* ERROR_NO_NETWORK, ERROR_EXTENDED_ERROR
*/
DWORD WINAPI MultinetGetConnectionPerformanceA(
LPNETRESOURCEA lpNetResource,
LPNETCONNECTINFOSTRUCT lpNetConnectInfoStruct )
{
FIXME( "(%p, %p): stub\n", lpNetResource, lpNetConnectInfoStruct );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* MultinetGetConnectionPerformanceW [MPR.26]
*/
DWORD WINAPI MultinetGetConnectionPerformanceW(
LPNETRESOURCEW lpNetResource,
LPNETCONNECTINFOSTRUCT lpNetConnectInfoStruct )
{
FIXME( "(%p, %p): stub\n", lpNetResource, lpNetConnectInfoStruct );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* MultinetGetErrorTextA [MPR.27]
*/
DWORD WINAPI MultinetGetErrorTextA( DWORD x, DWORD y, DWORD z )
{
FIXME( "(%lx, %lx, %lx): stub\n", x, y, z );
return 0;
}
/*****************************************************************
* MultinetGetErrorTextW [MPR.28]
*/
DWORD WINAPI MultinetGetErrorTextW( DWORD x, DWORD y, DWORD z )
{
FIXME( "(%lx, %lx, %lx ): stub\n", x, y, z );
return 0;
}

110
dlls/mpr/nps.c Normal file
View File

@ -0,0 +1,110 @@
/*
* MPR Network Provider Services functions
*/
#include "winbase.h"
#include "winnetwk.h"
#include "netspi.h"
#include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(mpr)
/*****************************************************************
* NPSAuthenticationDialogA [MPR.30]
*/
DWORD WINAPI NPSAuthenticationDialogA( LPAUTHDLGSTRUCTA lpAuthDlgStruct )
{
FIXME( "(%p): stub\n", lpAuthDlgStruct );
return WN_NOT_SUPPORTED;
}
/*****************************************************************
* NPSGetProviderHandleA [MPR.34]
*/
DWORD WINAPI NPSGetProviderHandleA( PHPROVIDER phProvider )
{
FIXME( "(%p): stub\n", phProvider );
return WN_NOT_SUPPORTED;
}
/*****************************************************************
* NPSGetProviderNameA [MPR.35]
*/
DWORD WINAPI NPSGetProviderNameA( HPROVIDER hProvider, LPCSTR *lpszProviderName )
{
FIXME( "(%p, %p): stub\n", hProvider, lpszProviderName );
return WN_NOT_SUPPORTED;
}
/*****************************************************************
* NPSGetSectionNameA [MPR.36]
*/
DWORD WINAPI NPSGetSectionNameA( HPROVIDER hProvider, LPCSTR *lpszSectionName )
{
FIXME( "(%p, %p): stub\n", hProvider, lpszSectionName );
return WN_NOT_SUPPORTED;
}
/*****************************************************************
* NPSSetExtendedErrorA [MPR.40]
*/
DWORD WINAPI NPSSetExtendedErrorA( DWORD NetSpecificError, LPSTR lpExtendedErrorText )
{
FIXME( "(%08lx, %s): stub\n", NetSpecificError, debugstr_a(lpExtendedErrorText) );
return WN_NOT_SUPPORTED;
}
/*****************************************************************
* NPSSetCustomTextA [MPR.39]
*/
VOID WINAPI NPSSetCustomTextA( LPSTR lpCustomErrorText )
{
FIXME( "(%s): stub\n", debugstr_a(lpCustomErrorText) );
}
/*****************************************************************
* NPSCopyStringA [MPR.31]
*/
DWORD WINAPI NPSCopyStringA( LPCSTR lpString, LPVOID lpBuffer, LPDWORD lpdwBufferSize )
{
FIXME( "(%s, %p, %p): stub\n", debugstr_a(lpString), lpBuffer, lpdwBufferSize );
return WN_NOT_SUPPORTED;
}
/*****************************************************************
* NPSDeviceGetNumberA [MPR.32]
*/
DWORD WINAPI NPSDeviceGetNumberA( LPSTR lpLocalName, LPDWORD lpdwNumber, LPDWORD lpdwType )
{
FIXME( "(%s, %p, %p): stub\n", debugstr_a(lpLocalName), lpdwNumber, lpdwType );
return WN_NOT_SUPPORTED;
}
/*****************************************************************
* NPSDeviceGetStringA [MPR.33]
*/
DWORD WINAPI NPSDeviceGetStringA( DWORD dwNumber, DWORD dwType, LPSTR lpLocalName, LPDWORD lpdwBufferSize )
{
FIXME( "(%ld, %ld, %p, %p): stub\n", dwNumber, dwType, lpLocalName, lpdwBufferSize );
return WN_NOT_SUPPORTED;
}
/*****************************************************************
* NPSNotifyRegisterA [MPR.38]
*/
DWORD WINAPI NPSNotifyRegisterA( enum NOTIFYTYPE NotifyType, NOTIFYCALLBACK pfNotifyCallBack )
{
FIXME( "(%d, %p): stub\n", NotifyType, pfNotifyCallBack );
return WN_NOT_SUPPORTED;
}
/*****************************************************************
* NPSNotifyGetContextA [MPR.37]
*/
LPVOID WINAPI NPSNotifyGetContextA( NOTIFYCALLBACK pfNotifyCallBack )
{
FIXME( "(%p): stub\n", pfNotifyCallBack );
return NULL;
}

80
dlls/mpr/pwcache.c Normal file
View File

@ -0,0 +1,80 @@
/*
* MPR Password Cache functions
*/
#include "winbase.h"
#include "winnetwk.h"
#include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(mpr)
/**************************************************************************
* WNetCachePassword [MPR.52] Saves password in cache
*
* RETURNS
* Success: WN_SUCCESS
* Failure: WN_ACCESS_DENIED, WN_BAD_PASSWORD, WN_BADVALUE, WN_NET_ERROR,
* WN_NOT_SUPPORTED, WN_OUT_OF_MEMORY
*/
DWORD WINAPI WNetCachePassword(
LPSTR pbResource, /* [in] Name of workgroup, computer, or resource */
WORD cbResource, /* [in] Size of name */
LPSTR pbPassword, /* [in] Buffer containing password */
WORD cbPassword, /* [in] Size of password */
BYTE nType) /* [in] Type of password to cache */
{
FIXME( "(%s, %d, %p, %d, %d): stub\n",
debugstr_a(pbResource), cbResource, pbPassword, cbPassword, nType );
return WN_SUCCESS;
}
/*****************************************************************
* WNetRemoveCachedPassword [MPR.95]
*/
UINT WINAPI WNetRemoveCachedPassword( LPSTR pbResource, WORD cbResource,
BYTE nType )
{
FIXME( "(%s, %d, %d): stub\n",
debugstr_a(pbResource), cbResource, nType );
return WN_SUCCESS;
}
/*****************************************************************
* WNetGetCachedPassword [MPR.69] Retrieves password from cache
*
* RETURNS
* Success: WN_SUCCESS
* Failure: WN_ACCESS_DENIED, WN_BAD_PASSWORD, WN_BAD_VALUE,
* WN_NET_ERROR, WN_NOT_SUPPORTED, WN_OUT_OF_MEMORY
*/
DWORD WINAPI WNetGetCachedPassword(
LPSTR pbResource, /* [in] Name of workgroup, computer, or resource */
WORD cbResource, /* [in] Size of name */
LPSTR pbPassword, /* [out] Buffer to receive password */
LPWORD pcbPassword, /* [out] Receives size of password */
BYTE nType) /* [in] Type of password to retrieve */
{
FIXME( "(%s, %d, %p, %p, %d): stub\n",
debugstr_a(pbResource), cbResource, pbPassword, pcbPassword, nType );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*******************************************************************
* WNetEnumCachedPasswords [MPR.61]
*/
UINT WINAPI WNetEnumCachedPasswords( LPSTR pbPrefix, WORD cbPrefix,
BYTE nType, FARPROC enumPasswordProc )
{
FIXME( "(%p, %d, %d, %p): stub\n",
pbPrefix, cbPrefix, nType, enumPasswordProc );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}

626
dlls/mpr/wnet.c Normal file
View File

@ -0,0 +1,626 @@
/*
* MPR WNet functions
*/
#include <ctype.h>
#include <string.h>
#include <sys/types.h>
#include <pwd.h>
#include <unistd.h>
#include "winbase.h"
#include "winnetwk.h"
#include "drive.h"
#include "heap.h"
#include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(mpr)
/*
* Browsing Functions
*/
/*********************************************************************
* WNetOpenEnumA [MPR.92]
*/
DWORD WINAPI WNetOpenEnumA( DWORD dwScope, DWORD dwType, DWORD dwUsage,
LPNETRESOURCEA lpNet, LPHANDLE lphEnum )
{
FIXME( "(%08lX, %08lX, %08lX, %p, %p): stub\n",
dwScope, dwType, dwUsage, lpNet, lphEnum );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetOpenEnumW [MPR.93]
*/
DWORD WINAPI WNetOpenEnumW( DWORD dwScope, DWORD dwType, DWORD dwUsage,
LPNETRESOURCEW lpNet, LPHANDLE lphEnum )
{
FIXME( "(%08lX, %08lX, %08lX, %p, %p): stub\n",
dwScope, dwType, dwUsage, lpNet, lphEnum );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetEnumResourceA [MPR.66]
*/
DWORD WINAPI WNetEnumResourceA( HANDLE hEnum, LPDWORD lpcCount,
LPVOID lpBuffer, LPDWORD lpBufferSize )
{
FIXME( "(%04X, %p, %p, %p): stub\n",
hEnum, lpcCount, lpBuffer, lpBufferSize );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetEnumResourceW [MPR.67]
*/
DWORD WINAPI WNetEnumResourceW( HANDLE hEnum, LPDWORD lpcCount,
LPVOID lpBuffer, LPDWORD lpBufferSize )
{
FIXME( "(%04X, %p, %p, %p): stub\n",
hEnum, lpcCount, lpBuffer, lpBufferSize );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetCloseEnum [MPR.58]
*/
DWORD WINAPI WNetCloseEnum( HANDLE hEnum )
{
FIXME( "(%04X): stub\n", hEnum );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetGetResourceInformationA [MPR.80]
*/
DWORD WINAPI WNetGetResourceInformationA( LPNETRESOURCEA lpNetResource,
LPVOID lpBuffer, LPDWORD cbBuffer,
LPSTR *lplpSystem )
{
FIXME( "(%p, %p, %p, %p): stub\n",
lpNetResource, lpBuffer, cbBuffer, lplpSystem );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetGetResourceInformationW [MPR.80]
*/
DWORD WINAPI WNetGetResourceInformationW( LPNETRESOURCEW lpNetResource,
LPVOID lpBuffer, LPDWORD cbBuffer,
LPWSTR *lplpSystem )
{
FIXME( "(%p, %p, %p, %p): stub\n",
lpNetResource, lpBuffer, cbBuffer, lplpSystem );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetGetResourceParentA [MPR.83]
*/
DWORD WINAPI WNetGetResourceParentA( LPNETRESOURCEA lpNetResource,
LPVOID lpBuffer, LPDWORD lpBufferSize )
{
FIXME( "(%p, %p, %p): stub\n",
lpNetResource, lpBuffer, lpBufferSize );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetGetResourceParentW [MPR.84]
*/
DWORD WINAPI WNetGetResourceParentW( LPNETRESOURCEW lpNetResource,
LPVOID lpBuffer, LPDWORD lpBufferSize )
{
FIXME( "(%p, %p, %p): stub\n",
lpNetResource, lpBuffer, lpBufferSize );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*
* Connection Functions
*/
/*********************************************************************
* WNetAddConnectionA [MPR.50]
*/
DWORD WINAPI WNetAddConnectionA( LPCSTR lpRemoteName, LPCSTR lpPassword,
LPCSTR lpLocalName )
{
FIXME( "(%s, %p, %s): stub\n",
debugstr_a(lpRemoteName), lpPassword, debugstr_a(lpLocalName) );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetAddConnectionW [MPR.51]
*/
DWORD WINAPI WNetAddConnectionW( LPCWSTR lpRemoteName, LPCWSTR lpPassword,
LPCWSTR lpLocalName )
{
FIXME( "(%s, %p, %s): stub\n",
debugstr_w(lpRemoteName), lpPassword, debugstr_w(lpLocalName) );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetAddConnection2A [MPR.46]
*/
DWORD WINAPI WNetAddConnection2A( LPNETRESOURCEA lpNetResource,
LPCSTR lpPassword, LPCSTR lpUserID,
DWORD dwFlags )
{
FIXME( "(%p, %p, %s, 0x%08lX): stub\n",
lpNetResource, lpPassword, debugstr_a(lpUserID), dwFlags );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetAddConnection2W [MPR.47]
*/
DWORD WINAPI WNetAddConnection2W( LPNETRESOURCEW lpNetResource,
LPCWSTR lpPassword, LPCWSTR lpUserID,
DWORD dwFlags )
{
FIXME( "(%p, %p, %s, 0x%08lX): stub\n",
lpNetResource, lpPassword, debugstr_w(lpUserID), dwFlags );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetAddConnection3A [MPR.48]
*/
DWORD WINAPI WNetAddConnection3A( HWND hwndOwner, LPNETRESOURCEA lpNetResource,
LPCSTR lpPassword, LPCSTR lpUserID,
DWORD dwFlags )
{
FIXME( "(%04x, %p, %p, %s, 0x%08lX), stub\n",
hwndOwner, lpNetResource, lpPassword, debugstr_a(lpUserID), dwFlags );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetAddConnection3W [MPR.49]
*/
DWORD WINAPI WNetAddConnection3W( HWND hwndOwner, LPNETRESOURCEW lpNetResource,
LPCWSTR lpPassword, LPCWSTR lpUserID,
DWORD dwFlags )
{
FIXME( "(%04x, %p, %p, %s, 0x%08lX), stub\n",
hwndOwner, lpNetResource, lpPassword, debugstr_w(lpUserID), dwFlags );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetUseConnectionA [MPR.100]
*/
DWORD WINAPI WNetUseConnectionA( HWND hwndOwner, LPNETRESOURCEA lpNetResource,
LPCSTR lpPassword, LPCSTR lpUserID, DWORD dwFlags,
LPSTR lpAccessName, LPDWORD lpBufferSize,
LPDWORD lpResult )
{
FIXME( "(%04x, %p, %p, %s, 0x%08lX, %s, %p, %p), stub\n",
hwndOwner, lpNetResource, lpPassword, debugstr_a(lpUserID), dwFlags,
debugstr_a(lpAccessName), lpBufferSize, lpResult );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetUseConnectionW [MPR.101]
*/
DWORD WINAPI WNetUseConnectionW( HWND hwndOwner, LPNETRESOURCEW lpNetResource,
LPCWSTR lpPassword, LPCWSTR lpUserID, DWORD dwFlags,
LPWSTR lpAccessName, LPDWORD lpBufferSize,
LPDWORD lpResult )
{
FIXME( "(%04x, %p, %p, %s, 0x%08lX, %s, %p, %p), stub\n",
hwndOwner, lpNetResource, lpPassword, debugstr_w(lpUserID), dwFlags,
debugstr_w(lpAccessName), lpBufferSize, lpResult );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetCancelConnectionA [MPR.55]
*/
DWORD WINAPI WNetCancelConnectionA( LPCSTR lpName, BOOL fForce )
{
FIXME( "(%s, %d), stub\n", debugstr_a(lpName), fForce );
return WN_SUCCESS;
}
/*********************************************************************
* WNetCancelConnectionW [MPR.56]
*/
DWORD WINAPI WNetCancelConnectionW( LPCWSTR lpName, BOOL fForce )
{
FIXME( "(%s, %d), stub\n", debugstr_w(lpName), fForce );
return WN_SUCCESS;
}
/*********************************************************************
* WNetCancelConnection2A [MPR.53]
*/
DWORD WINAPI WNetCancelConnection2A( LPCSTR lpName, DWORD dwFlags, BOOL fForce )
{
FIXME( "(%s, %08lX, %d), stub\n", debugstr_a(lpName), dwFlags, fForce );
return WN_SUCCESS;
}
/*********************************************************************
* WNetCancelConnection2W [MPR.54]
*/
DWORD WINAPI WNetCancelConnection2W( LPCWSTR lpName, DWORD dwFlags, BOOL fForce )
{
FIXME( "(%s, %08lX, %d), stub\n", debugstr_w(lpName), dwFlags, fForce );
return WN_SUCCESS;
}
/*****************************************************************
* WNetRestoreConnectionA [MPR.96]
*/
DWORD WINAPI WNetRestoreConnectionA( HWND hwndOwner, LPSTR lpszDevice )
{
FIXME( "(%04X, %s), stub\n", hwndOwner, debugstr_a(lpszDevice) );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetRestoreConnectionW [MPR.97]
*/
DWORD WINAPI WNetRestoreConnectionW( HWND hwndOwner, LPWSTR lpszDevice )
{
FIXME( "(%04X, %s), stub\n", hwndOwner, debugstr_w(lpszDevice) );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/**************************************************************************
* WNetGetConnectionA [MPR.71]
*
* RETURNS
* - WN_BAD_LOCALNAME lpLocalName makes no sense
* - WN_NOT_CONNECTED drive is a local drive
* - WN_MORE_DATA buffer isn't big enough
* - WN_SUCCESS success (net path in buffer)
*
*/
DWORD WINAPI WNetGetConnectionA( LPCSTR lpLocalName,
LPSTR lpRemoteName, LPDWORD lpBufferSize )
{
const char *path;
TRACE( "local %s\n", lpLocalName );
if (lpLocalName[1] == ':')
{
int drive = toupper(lpLocalName[0]) - 'A';
switch(DRIVE_GetType(drive))
{
case TYPE_INVALID:
return WN_BAD_LOCALNAME;
case TYPE_NETWORK:
path = DRIVE_GetLabel(drive);
if (strlen(path) + 1 > *lpBufferSize)
{
*lpBufferSize = strlen(path) + 1;
return WN_MORE_DATA;
}
strcpy( lpRemoteName, path );
*lpBufferSize = strlen(lpRemoteName) + 1;
return WN_SUCCESS;
case TYPE_FLOPPY:
case TYPE_HD:
case TYPE_CDROM:
TRACE("file is local\n");
return WN_NOT_CONNECTED;
default:
return WN_BAD_LOCALNAME;
}
}
return WN_BAD_LOCALNAME;
}
/**************************************************************************
* WNetGetConnectionW [MPR.72]
*/
DWORD WINAPI WNetGetConnectionW( LPCWSTR lpLocalName,
LPWSTR lpRemoteName, LPDWORD lpBufferSize )
{
DWORD x;
CHAR buf[200];
LPSTR lnA = HEAP_strdupWtoA( GetProcessHeap(), 0, lpLocalName );
DWORD ret = WNetGetConnectionA( lnA, buf, &x );
lstrcpyAtoW( lpRemoteName, buf );
*lpBufferSize=lstrlenW( lpRemoteName );
HeapFree( GetProcessHeap(), 0, lnA );
return ret;
}
/**************************************************************************
* WNetSetConnectionA [MPR.72]
*/
DWORD WINAPI WNetSetConnectionA( LPCSTR lpName, DWORD dwProperty,
LPVOID pvValue )
{
FIXME( "(%s, %08lX, %p): stub\n", debugstr_a(lpName), dwProperty, pvValue );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/**************************************************************************
* WNetSetConnectionW [MPR.72]
*/
DWORD WINAPI WNetSetConnectionW( LPCWSTR lpName, DWORD dwProperty,
LPVOID pvValue )
{
FIXME( "(%s, %08lX, %p): stub\n", debugstr_w(lpName), dwProperty, pvValue );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetGetUniversalNameA [MPR.85]
*/
DWORD WINAPI WNetGetUniversalNameA ( LPCSTR lpLocalPath, DWORD dwInfoLevel,
LPVOID lpBuffer, LPDWORD lpBufferSize )
{
FIXME( "(%s, 0x%08lX, %p, %p): stub\n",
debugstr_a(lpLocalPath), dwInfoLevel, lpBuffer, lpBufferSize);
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetGetUniversalNameW [MPR.86]
*/
DWORD WINAPI WNetGetUniversalNameW ( LPCWSTR lpLocalPath, DWORD dwInfoLevel,
LPVOID lpBuffer, LPDWORD lpBufferSize )
{
FIXME( "(%s, 0x%08lX, %p, %p): stub\n",
debugstr_w(lpLocalPath), dwInfoLevel, lpBuffer, lpBufferSize);
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*
* Other Functions
*/
/**************************************************************************
* WNetGetUserA [MPR.86]
*
* FIXME: we should not return ourselves, but the owner of the drive lpName
*/
DWORD WINAPI WNetGetUserA( LPCSTR lpName, LPSTR lpUserID, LPDWORD lpBufferSize )
{
struct passwd *pwd = getpwuid(getuid());
FIXME( "(%s, %p, %p): mostly stub\n",
debugstr_a(lpName), lpUserID, lpBufferSize );
if (pwd)
{
if ( strlen(pwd->pw_name) + 1 > *lpBufferSize )
{
*lpBufferSize = strlen(pwd->pw_name) + 1;
SetLastError(ERROR_MORE_DATA);
return ERROR_MORE_DATA;
}
strcpy( lpUserID, pwd->pw_name );
*lpBufferSize = strlen(pwd->pw_name) + 1;
return WN_SUCCESS;
}
/* FIXME: wrong return value */
SetLastError(ERROR_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*****************************************************************
* WNetGetUserW [MPR.87]
*/
DWORD WINAPI WNetGetUserW( LPCWSTR lpName, LPWSTR lpUserID, LPDWORD lpBufferSize )
{
FIXME( "(%s, %p, %p): mostly stub\n",
debugstr_w(lpName), lpUserID, lpBufferSize );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*********************************************************************
* WNetConnectionDialog [MPR.61]
*/
DWORD WINAPI WNetConnectionDialog( HWND hwnd, DWORD dwType )
{
FIXME( "(%04x, %08lX): stub\n", hwnd, dwType );
SetLastError(WN_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*********************************************************************
* WNetConnectionDialog1A [MPR.59]
*/
DWORD WINAPI WNetConnectionDialog1A( LPCONNECTDLGSTRUCTA lpConnDlgStruct )
{
FIXME( "(%p): stub\n", lpConnDlgStruct );
SetLastError(WN_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*********************************************************************
* WNetConnectionDialog1W [MPR.60]
*/
DWORD WINAPI WNetConnectionDialog1W( LPCONNECTDLGSTRUCTW lpConnDlgStruct )
{
FIXME( "(%p): stub\n", lpConnDlgStruct );
SetLastError(WN_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*********************************************************************
* WNetDisconnectDialog [MPR.64]
*/
DWORD WINAPI WNetDisconnectDialog( HWND hwnd, DWORD dwType )
{
FIXME( "(%04x, %08lX): stub\n", hwnd, dwType );
SetLastError(WN_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*********************************************************************
* WNetDisconnectDialog1A [MPR.62]
*/
DWORD WINAPI WNetDisconnectDialog1A( LPDISCDLGSTRUCTA lpConnDlgStruct )
{
FIXME( "(%p): stub\n", lpConnDlgStruct );
SetLastError(WN_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*********************************************************************
* WNetDisconnectDialog1W [MPR.63]
*/
DWORD WINAPI WNetDisconnectDialog1W( LPDISCDLGSTRUCTW lpConnDlgStruct )
{
FIXME( "(%p): stub\n", lpConnDlgStruct );
SetLastError(WN_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*********************************************************************
* WNetGetLastErrorA [MPR.75]
*/
DWORD WINAPI WNetGetLastErrorA( LPDWORD lpError,
LPSTR lpErrorBuf, DWORD nErrorBufSize,
LPSTR lpNameBuf, DWORD nNameBufSize )
{
FIXME( "(%p, %p, %ld, %p, %ld): stub\n",
lpError, lpErrorBuf, nErrorBufSize, lpNameBuf, nNameBufSize );
SetLastError(WN_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*********************************************************************
* WNetGetLastErrorW [MPR.76]
*/
DWORD WINAPI WNetGetLastErrorW( LPDWORD lpError,
LPWSTR lpErrorBuf, DWORD nErrorBufSize,
LPWSTR lpNameBuf, DWORD nNameBufSize )
{
FIXME( "(%p, %p, %ld, %p, %ld): stub\n",
lpError, lpErrorBuf, nErrorBufSize, lpNameBuf, nNameBufSize );
SetLastError(WN_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*********************************************************************
* WNetGetNetworkInformationA [MPR.77]
*/
DWORD WINAPI WNetGetNetworkInformationA( LPCSTR lpProvider,
LPNETINFOSTRUCT lpNetInfoStruct )
{
FIXME( "(%s, %p): stub\n", debugstr_a(lpProvider), lpNetInfoStruct );
SetLastError(WN_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*********************************************************************
* WNetGetNetworkInformationW [MPR.77]
*/
DWORD WINAPI WNetGetNetworkInformationW( LPCWSTR lpProvider,
LPNETINFOSTRUCT lpNetInfoStruct )
{
FIXME( "(%s, %p): stub\n", debugstr_w(lpProvider), lpNetInfoStruct );
SetLastError(WN_NO_NETWORK);
return ERROR_NO_NETWORK;
}
/*****************************************************************
* WNetGetProviderNameA [MPR.79]
*/
DWORD WINAPI WNetGetProviderNameA( DWORD dwNetType,
LPSTR lpProvider, LPDWORD lpBufferSize )
{
FIXME( "(%ld, %p, %p): stub\n", dwNetType, lpProvider, lpBufferSize );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}
/*****************************************************************
* WNetGetProviderNameW [MPR.80]
*/
DWORD WINAPI WNetGetProviderNameW( DWORD dwNetType,
LPWSTR lpProvider, LPDWORD lpBufferSize )
{
FIXME( "(%ld, %p, %p): stub\n", dwNetType, lpProvider, lpBufferSize );
SetLastError(WN_NO_NETWORK);
return WN_NO_NETWORK;
}

134
include/netspi.h Normal file
View File

@ -0,0 +1,134 @@
/*
* MPR - Network provider services
*/
#ifndef _NETSPI_H_
#define _NETSPI_H_
#include "windef.h"
/*
* Note: The Unicode variants of all these routines/structures
* apparently don't exist, at least not in Win95 ...
*/
#define HPROVIDER LPVOID
typedef HPROVIDER *PHPROVIDER;
typedef struct
{
DWORD cbStructure;
HWND hwndOwner;
LPCSTR lpResource;
LPSTR lpUsername;
DWORD cbUsername;
LPSTR lpPassword;
DWORD cbPassword;
LPSTR lpOrgUnit;
DWORD cbOrgUnit;
LPCSTR lpOUTitle;
LPCSTR lpExplainText;
LPCSTR lpDefaultUserName;
DWORD dwFlags;
} AUTHDLGSTRUCTA, *LPAUTHDLGSTRUCTA;
DECL_WINELIB_TYPE_AW(AUTHDLGSTRUCT)
DECL_WINELIB_TYPE_AW(LPAUTHDLGSTRUCT)
#define AUTHDLG_ENABLECACHE 0x00000001
#define AUTHDLG_CHECKCACHE 0x00000002
#define AUTHDLG_CACHEINVALID 0x00000004
#define AUTHDLG_USE_DEFAULT_NAME 0x00000008
#define AUTHDLG_CHECKDEFAULT_NAME 0x00000010
#define AUTHDLG_LOGON 0x00000020
#define AUTHDLG_ENABLECACHE 0x00000001
#define AUTHDLG_CHECKCACHE 0x00000002
#define AUTHDLG_CACHEINVALID 0x00000004
#define AUTHDLG_USE_DEFAULT_NAME 0x00000008
#define AUTHDLG_CHECKDEFAULT_NAME 0x00000010
#define AUTHDLG_LOGON 0x00000020
DWORD WINAPI NPSAuthenticationDialogA(LPAUTHDLGSTRUCTA);
#define NPSAuthenticationDialog WINELIB_NAME_AW(NPSAuthenticationDialog)
DWORD WINAPI NPSGetProviderHandleA(PHPROVIDER);
#define NPSGetProviderHandle WINELIB_NAME_AW(NPSGetProviderHandle)
DWORD WINAPI NPSGetProviderNameA(HPROVIDER,LPCSTR *);
#define NPSGetProviderName WINELIB_NAME_AW(NPSGetProviderName)
DWORD WINAPI NPSGetSectionNameA(HPROVIDER,LPCSTR *lpszSectionName);
#define NPSGetSectionName WINELIB_NAME_AW(NPSGetSectionName)
DWORD WINAPI NPSSetExtendedErrorA(DWORD,LPSTR);
#define NPSSetExtendedError WINELIB_NAME_AW(NPSSetExtendedError)
VOID WINAPI NPSSetCustomTextA(LPSTR);
#define NPSSetCustomText WINELIB_NAME_AW(NPSSetCustomText)
DWORD WINAPI NPSCopyStringA(LPCSTR,LPVOID,LPDWORD);
#define NPSCopyString WINELIB_NAME_AW(NPSCopyString)
DWORD WINAPI NPSDeviceGetNumberA(LPSTR,LPDWORD,LPDWORD);
#define NPSDeviceGetNumber WINELIB_NAME_AW(NPSDeviceGetNumber)
DWORD WINAPI NPSDeviceGetStringA(DWORD,DWORD,LPSTR,LPDWORD);
#define NPSDeviceGetString WINELIB_NAME_AW(NPSDeviceGetString)
enum NOTIFYTYPE { NotifyAddConnection,
NotifyCancelConnection,
NotifyGetConnectionPerformance };
#define NOTIFY_PRE 0x00
#define NOTIFY_POST 0x01
typedef struct
{
DWORD cbStructure;
DWORD dwNotifyStatus;
DWORD dwOperationStatus;
LPVOID lpNPContext;
} NOTIFYINFO, *LPNOTIFYINFO;
typedef struct
{
DWORD cbStructure;
HWND hwndOwner;
NETRESOURCEA NetResource;
DWORD dwAddFlags;
LPSTR lpAccessName;
LPDWORD lpBufferSize;
DWORD dwResult;
DWORD dwAddContext;
} NOTIFYADDA, *LPNOTIFYADDA;
#define CONNECT_CTXT_RESTORE 0x00000001
#define CONNECT_CTXT_GLOBAL 0x00000002
#define CONNECT_CTXT_PROVIDER 0x00000004
#define CONNECT_CTXT_SINGLE 0x00000008
typedef struct
{
DWORD cbStructure;
LPSTR lpName;
LPSTR lpProvider;
DWORD dwFlags;
BOOL fForce;
} NOTIFYCANCELA, *LPNOTIFYCANCELA;
typedef struct
{
DWORD cbStructure;
LPSTR lpRemoteName;
LPSTR lpProviderName;
LPNETCONNECTINFOSTRUCT lpNetConnectInfo;
} NOTIFYPERFORMANCEA, *LPNOTIFYPERFORMANCEA;
typedef DWORD (CALLBACK *NOTIFYCALLBACK)(LPNOTIFYINFO,LPVOID);
DWORD WINAPI NPSNotifyRegisterA(enum NOTIFYTYPE,NOTIFYCALLBACK);
#define NPSNotifyRegister WINELIB_NAME_AW(NPSNotifyRegister)
LPVOID WINAPI NPSNotifyGetContextA(NOTIFYCALLBACK);
#define NPSNotifyGetContext WINELIB_NAME_AW(NPSNotifyGetContext)
#endif _NETSPI_H_

267
include/wine/winnet16.h Normal file
View File

@ -0,0 +1,267 @@
/*
* Definitions for windows network service
*
* Copyright 1997 Andreas Mohr
* Copyright 1999 Ulrich Weigand
*/
#ifndef __WINE_WINNET16_H
#define __WINE_WINNET16_H
/*
* Remote printing
*/
typedef struct
{
WORD pqName;
WORD pqComment;
WORD pqStatus;
WORD pqJobcount;
WORD pqPrinters;
} QUEUESTRUCT16, *LPQUEUESTRUCT16;
#define WNPRQ_ACTIVE 0x0
#define WNPRQ_PAUSE 0x1
#define WNPRQ_ERROR 0x2
#define WNPRQ_PENDING 0x3
#define WNPRQ_PROBLEM 0x4
typedef struct
{
WORD pjId;
WORD pjUsername;
WORD pjParms;
WORD pjPosition;
WORD pjStatus;
DWORD pjSubmitted;
DWORD pjSize;
WORD pjCopies;
WORD pjComment;
} JOBSTRUCT16, *LPJOBSTRUCT16;
#define WNPRJ_QSTATUS 0x0007
#define WNPRJ_DEVSTATUS 0x0FF8
#define WNPRJ_QS_QUEUED 0x0000
#define WNPRJ_QS_PAUSED 0x0001
#define WNPRJ_QS_SPOOLING 0x0002
#define WNPRJ_QS_PRINTING 0x0003
#define WNPRJ_DS_COMPLETE 0x0008
#define WNPRJ_DS_INTERV 0x0010
#define WNPRJ_DS_ERROR 0x0020
#define WNPRJ_DS_DESTOFFLINE 0x0040
#define WNPRJ_DS_DESTPAUSED 0x0080
#define WNPRJ_DS_NOTIFY 0x0100
#define WNPRJ_DS_DESTNOPAPER 0x0200
#define WNPRJ_DS_DESTFORMCHG 0x0400
#define WNPRJ_DS_DESTCRTCHG 0x0800
#define WNPRJ_DS_DESTPENCHG 0x1000
#define SP_QUEUECHANGED 0x0500
#define WNJ_NULL_JOBID 0
WORD WINAPI WNetOpenJob16(LPSTR,LPSTR,WORD,LPINT16);
WORD WINAPI WNetCloseJob16(WORD,LPINT16,LPSTR);
WORD WINAPI WNetWriteJob16(HANDLE16,LPSTR,LPINT16);
WORD WINAPI WNetAbortJob16(LPSTR,WORD);
WORD WINAPI WNetHoldJob16(LPSTR,WORD);
WORD WINAPI WNetReleaseJob16(LPSTR,WORD);
WORD WINAPI WNetCancelJob16(LPSTR,WORD);
WORD WINAPI WNetSetJobCopies16(LPSTR,WORD,WORD);
WORD WINAPI WNetWatchQueue16(HWND16,LPSTR,LPSTR,WORD);
WORD WINAPI WNetUnwatchQueue16(LPSTR);
WORD WINAPI WNetLockQueueData16(LPSTR,LPSTR,LPQUEUESTRUCT16 *);
WORD WINAPI WNetUnlockQueueData16(LPSTR);
/*
* Connections
*/
WORD WINAPI WNetAddConnection16(LPSTR,LPSTR,LPSTR);
WORD WINAPI WNetCancelConnection16(LPSTR,BOOL16);
WORD WINAPI WNetGetConnection16(LPSTR,LPSTR,UINT16 *);
WORD WINAPI WNetRestoreConnection16(HWND16,LPSTR);
/*
* Capabilities
*/
WORD WINAPI WNetGetCaps16(WORD);
#define WNNC16_SPEC_VERSION 0x01
#define WNNC16_NET_TYPE 0x02
#define WNNC16_DRIVER_VERSION 0x03
#define WNNC16_USER 0x04
#define WNNC16_CONNECTION 0x06
#define WNNC16_PRINTING 0x07
#define WNNC16_DIALOG 0x08
#define WNNC16_ADMIN 0x09
#define WNNC16_ERROR 0x0a
#define WNNC16_PRINTMGREXT 0x0b
#define WNNC16_NET_NONE 0x0
#define WNNC16_NET_MSNet 0x1
#define WNNC16_NET_LanMan 0x2
#define WNNC16_NET_NetWare 0x3
#define WNNC16_NET_Vines 0x4
#define WNNC16_NET_10NET 0x5
#define WNNC16_NET_Locus 0x6
#define WNNC16_NET_SUN_PC_NFS 0x7
#define WNNC16_NET_LANstep 0x8
#define WNNC16_NET_9TILES 0x9
#define WNNC16_NET_LANtastic 0xa
#define WNNC16_NET_AS400 0xb
#define WNNC16_NET_FTP_NFS 0xc
#define WNNC16_NET_PATHWORKS 0xd
#define WNNC16_NET_LifeNet 0xe
#define WNNC16_NET_POWERLan 0xf
#define WNNC16_NET_MultiNet 0x8000
#define WNNC16_SUBNET_NONE 0x00
#define WNNC16_SUBNET_MSNet 0x01
#define WNNC16_SUBNET_LanMan 0x02
#define WNNC16_SUBNET_WinWorkgroups 0x04
#define WNNC16_SUBNET_NetWare 0x08
#define WNNC16_SUBNET_Vines 0x10
#define WNNC16_SUBNET_Other 0x80
#define WNNC16_CON_AddConnection 0x0001
#define WNNC16_CON_CancelConnection 0x0002
#define WNNC16_CON_GetConnections 0x0004
#define WNNC16_CON_AutoConnect 0x0008
#define WNNC16_CON_BrowseDialog 0x0010
#define WNNC16_CON_RestoreConnection 0x0020
#define WNNC16_PRT_OpenJob 0x0002
#define WNNC16_PRT_CloseJob 0x0004
#define WNNC16_PRT_HoldJob 0x0010
#define WNNC16_PRT_ReleaseJob 0x0020
#define WNNC16_PRT_CancelJob 0x0040
#define WNNC16_PRT_SetJobCopies 0x0080
#define WNNC16_PRT_WatchQueue 0x0100
#define WNNC16_PRT_UnwatchQueue 0x0200
#define WNNC16_PRT_LockQueueData 0x0400
#define WNNC16_PRT_UnlockQueueData 0x0800
#define WNNC16_PRT_ChangeMsg 0x1000
#define WNNC16_PRT_AbortJob 0x2000
#define WNNC16_PRT_NoArbitraryLock 0x4000
#define WNNC16_PRT_WriteJob 0x8000
#define WNNC16_DLG_DeviceMode 0x0001
#define WNNC16_DLG_BrowseDialog 0x0002
#define WNNC16_DLG_ConnectDialog 0x0004
#define WNNC16_DLG_DisconnectDialog 0x0008
#define WNNC16_DLG_ViewQueueDialog 0x0010
#define WNNC16_DLG_PropertyDialog 0x0020
#define WNNC16_DLG_ConnectionDialog 0x0040
#define WNNC16_DLG_PrinterConnectDialog 0x0080
#define WNNC16_DLG_SharesDialog 0x0100
#define WNNC16_DLG_ShareAsDialog 0x0200
#define WNNC16_ADM_GetDirectoryType 0x0001
#define WNNC16_ADM_DirectoryNotify 0x0002
#define WNNC16_ADM_LongNames 0x0004
#define WNNC16_ADM_SetDefaultDrive 0x0008
#define WNNC16_ERR_GetError 0x0001
#define WNNC16_ERR_GetErrorText 0x0002
/*
* Get User
*/
WORD WINAPI WNetGetUser16(LPSTR,LPINT16);
/*
* Browsing
*/
#define WNBD_CONN_UNKNOWN 0x0
#define WNBD_CONN_DISKTREE 0x1
#define WNBD_CONN_PRINTQ 0x3
#define WNBD_MAX_LENGTH 0x80
#define WNTYPE_DRIVE 1
#define WNTYPE_FILE 2
#define WNTYPE_PRINTER 3
#define WNTYPE_COMM 4
#define WNPS_FILE 0
#define WNPS_DIR 1
#define WNPS_MULT 2
WORD WINAPI WNetDeviceMode16(HWND16);
WORD WINAPI WNetBrowseDialog16(HWND16,WORD,LPSTR);
WORD WINAPI WNetConnectDialog16(HWND16,WORD);
WORD WINAPI WNetDisconnectDialog16(HWND16,WORD);
WORD WINAPI WNetConnectionDialog16(HWND16,WORD);
WORD WINAPI WNetViewQueueDialog16(HWND16,LPSTR);
WORD WINAPI WNetPropertyDialog16(HWND16,WORD,WORD,LPSTR,WORD);
WORD WINAPI WNetGetPropertyText16(WORD,WORD,LPSTR,LPSTR,WORD,WORD);
/*
* Admin
*/
#define WNDT_NORMAL 0
#define WNDT_NETWORK 1
#define WNDN_MKDIR 1
#define WNDN_RMDIR 2
#define WNDN_MVDIR 3
WORD WINAPI WNetGetDirectoryType16(LPSTR,LPINT16);
WORD WINAPI WNetDirectoryNotify16(HWND16,LPSTR,WORD);
/*
* Status codes
*/
WORD WINAPI WNetGetError16(LPINT16);
WORD WINAPI WNetGetErrorText16(WORD,LPSTR,LPINT16);
WORD WINAPI WNetErrorText16(WORD,LPSTR,WORD);
#define WN16_SUCCESS 0x0000
#define WN16_NOT_SUPPORTED 0x0001
#define WN16_NET_ERROR 0x0002
#define WN16_MORE_DATA 0x0003
#define WN16_BAD_POINTER 0x0004
#define WN16_BAD_VALUE 0x0005
#define WN16_BAD_PASSWORD 0x0006
#define WN16_ACCESS_DENIED 0x0007
#define WN16_FUNCTION_BUSY 0x0008
#define WN16_WINDOWS_ERROR 0x0009
#define WN16_BAD_USER 0x000A
#define WN16_OUT_OF_MEMORY 0x000B
#define WN16_CANCEL 0x000C
#define WN16_CONTINUE 0x000D
#define WN16_NOT_CONNECTED 0x0030
#define WN16_OPEN_FILES 0x0031
#define WN16_BAD_NETNAME 0x0032
#define WN16_BAD_LOCALNAME 0x0033
#define WN16_ALREADY_CONNECTED 0x0034
#define WN16_DEVICE_ERROR 0x0035
#define WN16_CONNECTION_CLOSED 0x0036
#define WN16_BAD_JOBID 0x0040
#define WN16_JOB_NOT_FOUND 0x0041
#define WN16_JOB_NOT_HELD 0x0042
#define WN16_BAD_QUEUE 0x0043
#define WN16_BAD_FILE_HANDLE 0x0044
#define WN16_CANT_SET_COPIES 0x0045
#define WN16_ALREADY_LOCKED 0x0046
#define WN16_NO_ERROR 0x0050
#endif /* __WINE_WINNET16_H */

View File

@ -250,8 +250,54 @@ extern int WIN32_LastError;
#define ERROR_IO_DEVICE 1117
#define ERROR_POSSIBLE_DEADLOCK 1131
#define ERROR_BAD_DEVICE 1200
#define ERROR_CONNECTION_UNAVAIL 1201
#define ERROR_DEVICE_ALREADY_REMEMBERED 1202
#define ERROR_NO_NET_OR_BAD_PATH 1203
#define ERROR_BAD_PROVIDER 1204
#define ERROR_CANNOT_OPEN_PROFILE 1205
#define ERROR_BAD_PROFILE 1206
#define ERROR_NOT_CONTAINER 1207
#define ERROR_EXTENDED_ERROR 1208
#define ERROR_INVALID_GROUPNAME 1209
#define ERROR_INVALID_COMPUTERNAME 1210
#define ERROR_INVALID_EVENTNAME 1211
#define ERROR_INVALID_DOMAINNAME 1212
#define ERROR_INVALID_SERVICENAME 1213
#define ERROR_INVALID_NETNAME 1214
#define ERROR_INVALID_SHARENAME 1215
#define ERROR_INVALID_PASSWORDNAME 1216
#define ERROR_INVALID_MESSAGENAME 1217
#define ERROR_INVALID_MESSAGEDEST 1218
#define ERROR_SESSION_CREDENTIAL_CONFLICT 1219
#define ERROR_REMOTE_SESSION_LIMIT_EXCEEDED 1220
#define ERROR_DUP_DOMAINNAME 1221
#define ERROR_NO_NETWORK 1222
#define ERROR_CANCELLED 1223
#define ERROR_USER_MAPPED_FILE 1224
#define ERROR_CONNECTION_REFUSED 1225
#define ERROR_GRACEFUL_DISCONNECT 1226
#define ERROR_ADDRESS_ALREADY_ASSOCIATED 1227
#define ERROR_ADDRESS_NOT_ASSOCIATED 1228
#define ERROR_CONNECTION_INVALID 1229
#define ERROR_CONNECTION_ACTIVE 1230
#define ERROR_NETWORK_UNREACHABLE 1231
#define ERROR_HOST_UNREACHABLE 1232
#define ERROR_PROTOCOL_UNREACHABLE 1233
#define ERROR_PORT_UNREACHABLE 1234
#define ERROR_REQUEST_ABORTED 1235
#define ERROR_CONNECTION_ABORTED 1236
#define ERROR_RETRY 1237
#define ERROR_CONNECTION_COUNT_LIMIT 1238
#define ERROR_LOGIN_TIME_RESTRICTION 1239
#define ERROR_LOGIN_WKSTA_RESTRICTION 1240
#define ERROR_INCORRECT_ADDRESS 1241
#define ERROR_ALREADY_REGISTERED 1242
#define ERROR_SERVICE_NOT_FOUND 1243
#define ERROR_NOT_AUTHENTICATED 1244
#define ERROR_NOT_LOGGED_ON 1245
#define ERROR_CONTINUE 1246
#define ERROR_ALREADY_INITIALIZED 1247
#define ERROR_NO_MORE_DEVICES 1248
#define ERROR_PRIVILEGE_NOT_HELD 1314
#define ERROR_INVALID_WINDOW_HANDLE 1400
#define ERROR_CANNOT_FIND_WND_CLASS 1407
@ -271,6 +317,11 @@ extern int WIN32_LastError;
#define ERROR_INVALID_PRINTER_COMMAND 1803
#define ERROR_INVALID_DATATYPE 1804
#define ERROR_INVALID_ENVIRONMENT 1805
#define ERROR_BAD_USERNAME 2202
#define ERROR_NOT_CONNECTED 2250
#define ERROR_OPEN_FILES 2401
#define ERROR_ACTIVE_CONNECTIONS 2402
#define ERROR_DEVICE_IN_USE 2404
/* HRESULT values for OLE, SHELL and other Interface stuff */
/* the codes 4000-40ff are reserved for OLE */

View File

@ -1,8 +1,69 @@
#ifndef _WINNETWK_H_
#define _WINNETWK_H_
#include "windef.h"
#include "winerror.h"
/*
* Network types
*/
#define WNNC_NET_MSNET 0x00010000
#define WNNC_NET_LANMAN 0x00020000
#define WNNC_NET_NETWARE 0x00030000
#define WNNC_NET_VINES 0x00040000
#define WNNC_NET_10NET 0x00050000
#define WNNC_NET_LOCUS 0x00060000
#define WNNC_NET_SUN_PC_NFS 0x00070000
#define WNNC_NET_LANSTEP 0x00080000
#define WNNC_NET_9TILES 0x00090000
#define WNNC_NET_LANTASTIC 0x000A0000
#define WNNC_NET_AS400 0x000B0000
#define WNNC_NET_FTP_NFS 0x000C0000
#define WNNC_NET_PATHWORKS 0x000D0000
#define WNNC_NET_LIFENET 0x000E0000
#define WNNC_NET_POWERLAN 0x000F0000
#define WNNC_NET_BWNFS 0x00100000
#define WNNC_NET_COGENT 0x00110000
#define WNNC_NET_FARALLON 0x00120000
#define WNNC_NET_APPLETALK 0x00130000
#define WNNC_NET_INTERGRAPH 0x00140000
/*
* Network resources
*/
#define RESOURCE_CONNECTED 0x00000001
#define RESOURCE_GLOBALNET 0x00000002
#define RESOURCE_REMEMBERED 0x00000003
#define RESOURCE_RECENT 0x00000004
#define RESOURCE_CONTEXT 0x00000005
#define RESOURCETYPE_ANY 0x00000000
#define RESOURCETYPE_DISK 0x00000001
#define RESOURCETYPE_PRINT 0x00000002
#define RESOURCETYPE_RESERVED 0x00000008
#define RESOURCETYPE_UNKNOWN 0xFFFFFFFF
#define RESOURCEUSAGE_CONNECTABLE 0x00000001
#define RESOURCEUSAGE_CONTAINER 0x00000002
#define RESOURCEUSAGE_NOLOCALDEVICE 0x00000004
#define RESOURCEUSAGE_SIBLING 0x00000008
#define RESOURCEUSAGE_ALL (RESOURCEUSAGE_CONNECTABLE | RESOURCEUSAGE_CONTAINER)
#define RESOURCEUSAGE_RESERVED 0x80000000
#define RESOURCEDISPLAYTYPE_GENERIC 0x00000000
#define RESOURCEDISPLAYTYPE_DOMAIN 0x00000001
#define RESOURCEDISPLAYTYPE_SERVER 0x00000002
#define RESOURCEDISPLAYTYPE_SHARE 0x00000003
#define RESOURCEDISPLAYTYPE_FILE 0x00000004
#define RESOURCEDISPLAYTYPE_GROUP 0x00000005
#define RESOURCEDISPLAYTYPE_NETWORK 0x00000006
#define RESOURCEDISPLAYTYPE_ROOT 0x00000007
#define RESOURCEDISPLAYTYPE_SHAREADMIN 0x00000008
#define RESOURCEDISPLAYTYPE_DIRECTORY 0x00000009
#define RESOURCEDISPLAYTYPE_TREE 0x0000000A
typedef struct {
DWORD dwScope;
@ -29,6 +90,53 @@ typedef struct {
DECL_WINELIB_TYPE_AW(NETRESOURCE)
DECL_WINELIB_TYPE_AW(LPNETRESOURCE)
/*
* Network connections
*/
#define NETPROPERTY_PERSISTENT 1
#define CONNECT_UPDATE_PROFILE 0x00000001
#define CONNECT_UPDATE_RECENT 0x00000002
#define CONNECT_TEMPORARY 0x00000004
#define CONNECT_INTERACTIVE 0x00000008
#define CONNECT_PROMPT 0x00000010
#define CONNECT_NEED_DRIVE 0x00000020
#define CONNECT_REFCOUNT 0x00000040
#define CONNECT_REDIRECT 0x00000080
#define CONNECT_LOCALDRIVE 0x00000100
#define CONNECT_CURRENT_MEDIA 0x00000200
DWORD WINAPI WNetAddConnectionA(LPCSTR,LPCSTR,LPCSTR);
DWORD WINAPI WNetAddConnectionW(LPCWSTR,LPCWSTR,LPCWSTR);
#define WNetAddConnection WINELIB_NAME_AW(WNetAddConnection)
DWORD WINAPI WNetAddConnection2A(LPNETRESOURCEA,LPCSTR,LPCSTR,DWORD);
DWORD WINAPI WNetAddConnection2W(LPNETRESOURCEW,LPCWSTR,LPCWSTR,DWORD);
#define WNetAddConnection2 WINELIB_NAME_AW(WNetAddConnection2)
DWORD WINAPI WNetAddConnection3A(HWND,LPNETRESOURCEA,LPCSTR,LPCSTR,DWORD);
DWORD WINAPI WNetAddConnection3W(HWND,LPNETRESOURCEW,LPCWSTR,LPCWSTR,DWORD);
#define WNetAddConnection3 WINELIB_NAME_AW(WNetAddConnection3)
DWORD WINAPI WNetCancelConnectionA(LPCSTR,BOOL);
DWORD WINAPI WNetCancelConnectionW(LPCWSTR,BOOL);
#define WNetCancelConnection WINELIB_NAME_AW(WNetCancelConnection)
DWORD WINAPI WNetCancelConnection2A(LPCSTR,DWORD,BOOL);
DWORD WINAPI WNetCancelConnection2W(LPCWSTR,DWORD,BOOL);
#define WNetCancelConnection2 WINELIB_NAME_AW(WNetCancelConnection2)
DWORD WINAPI WNetGetConnectionA(LPCSTR,LPSTR,LPDWORD);
DWORD WINAPI WNetGetConnectionW(LPCWSTR,LPWSTR,LPDWORD);
#define WNetGetConnection WINELIB_NAME_AW(WNetGetConnection)
DWORD WINAPI WNetUseConnectionA(HWND,LPNETRESOURCEA,LPCSTR,LPCSTR,DWORD,LPSTR,LPDWORD,LPDWORD);
DWORD WINAPI WNetUseConnectionW(HWND,LPNETRESOURCEW,LPCWSTR,LPCWSTR,DWORD,LPWSTR,LPDWORD,LPDWORD);
#define WNetUseConnection WINELIB_NAME_AW(WNetUseConnection)
DWORD WINAPI WNetSetConnectionA(LPCSTR,DWORD,LPVOID);
DWORD WINAPI WNetSetConnectionW(LPCWSTR,DWORD,LPVOID);
#define WNetSetConnection WINELIB_NAME_AW(WNetSetConnection)
/*
* Network connection dialogs
*/
typedef struct {
DWORD cbStructure; /* size of this structure in bytes */
HWND hwndOwner; /* owner window for the dialog */
@ -47,8 +155,6 @@ typedef struct {
DECL_WINELIB_TYPE_AW(CONNECTDLGSTRUCT)
DECL_WINELIB_TYPE_AW(LPCONNECTDLGSTRUCT)
/**/
#define CONNDLG_RO_PATH 0x00000001 /* Resource path should be read-only */
#define CONNDLG_CONN_POINT 0x00000002 /* Netware -style movable connection point enabled */
#define CONNDLG_USE_MRU 0x00000004 /* Use MRU combobox */
@ -56,6 +162,176 @@ DECL_WINELIB_TYPE_AW(LPCONNECTDLGSTRUCT)
#define CONNDLG_PERSIST 0x00000010 /* Force persistent connection */
#define CONNDLG_NOT_PERSIST 0x00000020 /* Force connection NOT persistent */
typedef struct {
DWORD cbStructure; /* size of this structure in bytes */
HWND hwndOwner; /* owner window for the dialog */
LPSTR lpLocalName; /* local device name */
LPSTR lpRemoteName; /* network resource name */
DWORD dwFlags; /* flags */
} DISCDLGSTRUCTA, *LPDISCDLGSTRUCTA;
typedef struct {
DWORD cbStructure; /* size of this structure in bytes */
HWND hwndOwner; /* owner window for the dialog */
LPWSTR lpLocalName; /* local device name */
LPWSTR lpRemoteName; /* network resource name */
DWORD dwFlags; /* flags */
} DISCDLGSTRUCTW, *LPDISCDLGSTRUCTW;
DECL_WINELIB_TYPE_AW(DISCDLGSTRUCT)
DECL_WINELIB_TYPE_AW(LPDISCDLGSTRUCT)
#define DISC_UPDATE_PROFILE 0x00000001
#define DISC_NO_FORCE 0x00000040
DWORD WINAPI WNetConnectionDialog(HWND,DWORD);
DWORD WINAPI WNetDisconnectDialog(HWND,DWORD);
DWORD WINAPI WNetConnectionDialog1A(LPCONNECTDLGSTRUCTA);
DWORD WINAPI WNetConnectionDialog1W(LPCONNECTDLGSTRUCTW);
#define WNetConnectionDialog1 WINELIB_NAME_AW(WNetConnectionDialog1)
DWORD WINAPI WNetDisconnectDialog1A(LPDISCDLGSTRUCTA);
DWORD WINAPI WNetDisconnectDialog1W(LPDISCDLGSTRUCTW);
#define WNetDisconnectDialog1 WINELIB_NAME_AW(WNetDisconnectDialog1)
/*
* Network browsing
*/
DWORD WINAPI WNetOpenEnumA(DWORD,DWORD,DWORD,LPNETRESOURCEA,LPHANDLE);
DWORD WINAPI WNetOpenEnumW(DWORD,DWORD,DWORD,LPNETRESOURCEW,LPHANDLE);
#define WNetOpenEnum WINELIB_NAME_AW(WNetOpenEnum)
DWORD WINAPI WNetEnumResourceA(HANDLE,LPDWORD,LPVOID,LPDWORD);
DWORD WINAPI WNetEnumResourceW(HANDLE,LPDWORD,LPVOID,LPDWORD);
#define WNetEnumResource WINELIB_NAME_AW(WNetEnumResource)
DWORD WINAPI WNetCloseEnum(HANDLE);
/*
* Universal naming
*/
#define UNIVERSAL_NAME_INFO_LEVEL 0x00000001
#define REMOTE_NAME_INFO_LEVEL 0x00000002
typedef struct {
LPSTR lpUniversalName;
} UNIVERSAL_NAME_INFOA, *LPUNIVERSAL_NAME_INFOA;
typedef struct {
LPWSTR lpUniversalName;
} UNIVERSAL_NAME_INFOW, *LPUNIVERSAL_NAME_INFOW;
DECL_WINELIB_TYPE_AW(UNIVERSAL_NAME_INFO)
DECL_WINELIB_TYPE_AW(LPUNIVERSAL_NAME_INFO)
typedef struct {
LPSTR lpUniversalName;
LPSTR lpConnectionName;
LPSTR lpRemainingPath;
}REMOTE_NAME_INFOA, *LPREMOTE_NAME_INFOA;
typedef struct {
LPWSTR lpUniversalName;
LPWSTR lpConnectionName;
LPWSTR lpRemainingPath;
}REMOTE_NAME_INFOW, *LPREMOTE_NAME_INFOW;
DECL_WINELIB_TYPE_AW(REMOTE_NAME_INFO)
DECL_WINELIB_TYPE_AW(LPREMOTE_NAME_INFO)
DWORD WINAPI WNetGetUniversalNameA(LPCSTR,DWORD,LPVOID,LPDWORD);
DWORD WINAPI WNetGetUniversalNameW(LPCWSTR,DWORD,LPVOID,LPDWORD);
#define WNetGetUniversalName WINELIB_NAME_AW(WNetGetUniversalName)
/*
* Other
*/
DWORD WINAPI WNetGetUserA(LPCSTR,LPSTR,LPDWORD);
DWORD WINAPI WNetGetUserW(LPCWSTR,LPWSTR,LPDWORD);
#define WNetGetUser WINELIB_NAME_AW(WNetGetUser)
#define WNFMT_MULTILINE 0x01
#define WNFMT_ABBREVIATED 0x02
#define WNFMT_INENUM 0x10
#define WNFMT_CONNECTION 0x20
DWORD WINAPI WNetGetProviderNameA(DWORD,LPSTR,LPDWORD);
DWORD WINAPI WNetGetProviderNameW(DWORD,LPWSTR,LPDWORD);
#define WNetGetProviderName WINELIB_NAME_AW(WNetGetProviderName)
typedef struct {
DWORD cbStructure;
DWORD dwProviderVersion;
DWORD dwStatus;
DWORD dwCharacteristics;
DWORD dwHandle;
WORD wNetType;
DWORD dwPrinters;
DWORD dwDrives;
} NETINFOSTRUCT, *LPNETINFOSTRUCT;
#define NETINFO_DLL16 0x00000001
#define NETINFO_DISKRED 0x00000004
#define NETINFO_PRINTERRED 0x00000008
DWORD WINAPI WNetGetNetworkInformationA(LPCSTR,LPNETINFOSTRUCT);
DWORD WINAPI WNetGetNetworkInformationW(LPCWSTR,LPNETINFOSTRUCT);
#define WNetGetNetworkInformation WINELIB_NAME_AW(WNetGetNetworkInformation)
/*
* Status codes
*/
DWORD WINAPI WNetGetLastErrorA(LPDWORD,LPSTR,DWORD,LPSTR,DWORD);
DWORD WINAPI WNetGetLastErrorW(LPDWORD,LPWSTR,DWORD,LPWSTR,DWORD);
#define WNetGetLastError WINELIB_NAME_AW(WNetGetLastError)
#define WN_SUCCESS NO_ERROR
#define WN_NO_ERROR NO_ERROR
#define WN_NOT_SUPPORTED ERROR_NOT_SUPPORTED
#define WN_CANCEL ERROR_CANCELLED
#define WN_RETRY ERROR_RETRY
#define WN_NET_ERROR ERROR_UNEXP_NET_ERR
#define WN_MORE_DATA ERROR_MORE_DATA
#define WN_BAD_POINTER ERROR_INVALID_ADDRESS
#define WN_BAD_VALUE ERROR_INVALID_PARAMETER
#define WN_BAD_USER ERROR_BAD_USERNAME
#define WN_BAD_PASSWORD ERROR_INVALID_PASSWORD
#define WN_ACCESS_DENIED ERROR_ACCESS_DENIED
#define WN_FUNCTION_BUSY ERROR_BUSY
#define WN_WINDOWS_ERROR ERROR_UNEXP_NET_ERR
#define WN_OUT_OF_MEMORY ERROR_NOT_ENOUGH_MEMORY
#define WN_NO_NETWORK ERROR_NO_NETWORK
#define WN_EXTENDED_ERROR ERROR_EXTENDED_ERROR
#define WN_BAD_LEVEL ERROR_INVALID_LEVEL
#define WN_BAD_HANDLE ERROR_INVALID_HANDLE
#define WN_NOT_INITIALIZING ERROR_ALREADY_INITIALIZED
#define WN_NO_MORE_DEVICES ERROR_NO_MORE_DEVICES
#define WN_NOT_CONNECTED ERROR_NOT_CONNECTED
#define WN_OPEN_FILES ERROR_OPEN_FILES
#define WN_DEVICE_IN_USE ERROR_DEVICE_IN_USE
#define WN_BAD_NETNAME ERROR_BAD_NET_NAME
#define WN_BAD_LOCALNAME ERROR_BAD_DEVICE
#define WN_ALREADY_CONNECTED ERROR_ALREADY_ASSIGNED
#define WN_DEVICE_ERROR ERROR_GEN_FAILURE
#define WN_CONNECTION_CLOSED ERROR_CONNECTION_UNAVAIL
#define WN_NO_NET_OR_BAD_PATH ERROR_NO_NET_OR_BAD_PATH
#define WN_BAD_PROVIDER ERROR_BAD_PROVIDER
#define WN_CANNOT_OPEN_PROFILE ERROR_CANNOT_OPEN_PROFILE
#define WN_BAD_PROFILE ERROR_BAD_PROFILE
#define WN_BAD_DEV_TYPE ERROR_BAD_DEV_TYPE
#define WN_DEVICE_ALREADY_REMEMBERED ERROR_DEVICE_ALREADY_REMEMBERED
#define WN_NO_MORE_ENTRIES ERROR_NO_MORE_ITEMS
#define WN_NOT_CONTAINER ERROR_NOT_CONTAINER
#define WN_NOT_AUTHENTICATED ERROR_NOT_AUTHENTICATED
#define WN_NOT_LOGGED_ON ERROR_NOT_LOGGED_ON
#define WN_NOT_VALIDATED ERROR_NO_LOGON_SERVERS
/*
* Multinet (for Shell)
*/
typedef struct {
DWORD cbStructure;
@ -65,33 +341,17 @@ typedef struct {
DWORD dwOptDataSize;
} NETCONNECTINFOSTRUCT,*LPNETCONNECTINFOSTRUCT;
#define WNCON_FORNETCARD 0x00000001
#define WNCON_NOTROUTED 0x00000002
#define WNCON_SLOWLINK 0x00000004
#define WNCON_DYNAMIC 0x00000008
UINT WINAPI WNetAddConnection2A(LPNETRESOURCEA,LPCSTR,LPCSTR,DWORD);
UINT WINAPI WNetAddConnection2W(LPNETRESOURCEW,LPCWSTR,LPCWSTR,DWORD);
#define WNetAddConnection2 WINELIB_NAME_AW(WNetAddConnection2)
UINT WINAPI WNetAddConnection3A(HWND,LPNETRESOURCEA,LPCSTR,LPCSTR,DWORD);
UINT WINAPI WNetAddConnection3W(HWND,LPNETRESOURCEW,LPCWSTR,LPCWSTR,DWORD);
#define WNetAddConnection3 WINELIB_NAME_AW(WNetAddConnection3)
UINT WINAPI WNetConnectionDialog1(HWND,DWORD);
UINT WINAPI WNetConnectionDialog1A(LPCONNECTDLGSTRUCTA);
UINT WINAPI WNetConnectionDialog1W(LPCONNECTDLGSTRUCTW);
#define WNetConnectionDialog1 WINELIB_NAME_AW(WNetConnectionDialog1)
UINT WINAPI MultinetGetErrorTextA(DWORD,DWORD,DWORD);
UINT WINAPI MultinetGetErrorTextW(DWORD,DWORD,DWORD);
DWORD WINAPI MultinetGetConnectionPerformanceA(LPNETRESOURCEA,LPNETCONNECTINFOSTRUCT);
DWORD WINAPI MultinetGetConnectionPerformanceW(LPNETRESOURCEW,LPNETCONNECTINFOSTRUCT);
#define MultinetGetConnectionPerformance WINELIB_NAME_AW(MultinetGetConnectionPerformance)
DWORD WINAPI MultinetGetErrorTextA(DWORD,DWORD,DWORD);
DWORD WINAPI MultinetGetErrorTextW(DWORD,DWORD,DWORD);
#define MultinetGetErrorText WINELIB_NAME_AW(MultinetGetErrorText)
DWORD WINAPI NPSGetSectionNameA(DWORD,LPCSTR*);
DWORD WINAPI NPSGetSectionNameW(DWORD,LPCWSTR*);
#define NPSGetSectionName WINELIB_NAME_AW(NPSGetSectionName)
#define RESOURCETYPE_ANY 0x00000000
#define RESOURCETYPE_DISK 0x00000001
#define RESOURCETYPE_PRINT 0x00000002
#define CONNECT_UPDATE_PROFILE 0x00000001
#define CONNECT_UPDATE_RECENT 0x00000002
#define CONNECT_TEMPORARY 0x00000004
#define CONNECT_INTERACTIVE 0x00000008
#define CONNECT_PROMPT 0x00000010
#define CONNECT_NEED_DRIVE 0x00000020
#endif /* _WINNETWK_H_ */

View File

@ -3569,9 +3569,6 @@ HWND WINAPI WindowFromPoint(POINT);
BOOL WINAPI WinHelpA(HWND,LPCSTR,UINT,DWORD);
BOOL WINAPI WinHelpW(HWND,LPCWSTR,UINT,DWORD);
#define WinHelp WINELIB_NAME_AW(WinHelp)
UINT WINAPI WNetAddConnectionA(LPCSTR,LPCSTR,LPCSTR);
UINT WINAPI WNetAddConnectionW(LPCWSTR,LPCWSTR,LPCWSTR);
#define WNetAddConnection WINELIB_NAME_AW(WNetAddConnection)
INT WINAPIV wsnprintfA(LPSTR,UINT,LPCSTR,...);
INT WINAPIV wsnprintfW(LPWSTR,UINT,LPCWSTR,...);
#define wsnprintf WINELIB_NAME_AW(wsnprintf)

View File

@ -1,131 +0,0 @@
/* Definitions for windows network service
*
* Copyright 1997 Andreas Mohr
*/
#ifndef __WINE_WNET_H
#define __WINE_WNET_H
#include "windef.h"
#include "winerror.h"
#define WNDN_MKDIR 1
#define WNDN_RMDIR 2
#define WNDN_MVDIR 3
#define WN_SUCCESS 0x0000
#define WN_NOT_SUPPORTED 0x0001
#define WN_NET_ERROR 0x0002
#define WN_MORE_DATA 0x0003
#define WN_BAD_POINTER 0x0004
#define WN_BAD_VALUE 0x0005
#define WN_BAD_PASSWORD 0x0006
#define WN_ACCESS_DENIED 0x0007
#define WN_FUNCTION_BUSY 0x0008
#define WN_WINDOWS_ERROR 0x0009
#define WN_BAD_USER 0x000A
#define WN_OUT_OF_MEMORY 0x000B
#define WN_CANCEL 0x000C
#define WN_CONTINUE 0x000D
#define WN_BAD_HANDLE ERROR_INVALID_HANDLE
#define WN_NOT_CONNECTED 0x0030
#define WN_OPEN_FILES 0x0031
#define WN_BAD_NETNAME 0x0032
#define WN_BAD_LOCALNAME 0x0033
#define WN_ALREADY_CONNECTED 0x0034
#define WN_DEVICE_ERROR 0x0035
#define WN_CONNECTION_CLOSED 0x0036
#define WN_NO_NETWORK ERROR_NO_NETWORK
#define WNNC_SPEC_VERSION 0x01
#define WNNC_NET_TYPE 0x02
#define WNNC_DRIVER_VERSION 0x03
#define WNNC_USER 0x04
/*#define WNNC_5 0x05*/
#define WNNC_CONNECTION 0x06
#define WNNC_PRINTING 0x07
#define WNNC_DIALOG 0x08
#define WNNC_ADMIN 0x09
#define WNNC_ERROR 0x0a
#define WNNC_PRINTMGREXT 0x0b
#define WNNC_NET_NONE 0x0
#define WNNC_NET_MSNet 0x1
#define WNNC_NET_LanMan 0x2
#define WNNC_NET_NetWare 0x3
#define WNNC_NET_Vines 0x4
#define WNNC_NET_10NET 0x5
#define WNNC_NET_Locus 0x6
#define WNNC_NET_SUN_PC_NFS 0x7
#define WNNC_NET_LANstep 0x8
#define WNNC_NET_9TILES 0x9
#define WNNC_NET_LANtastic 0xa
#define WNNC_NET_AS400 0xb
#define WNNC_NET_FTP_NFS 0xc
#define WNNC_NET_PATHWORKS 0xd
#define WNNC_NET_LifeNet 0xe
#define WNNC_NET_POWERLan 0xf
#define WNNC_NET_MultiNet 0x8000
#define WNNC_SUBNET_NONE 0x00
#define WNNC_SUBNET_MSNet 0x01
#define WNNC_SUBNET_LanMan 0x02
#define WNNC_SUBNET_WinWorkgroups 0x04
#define WNNC_SUBNET_NetWare 0x08
#define WNNC_SUBNET_Vines 0x10
#define WNNC_SUBNET_Other 0x80
#define WNNC_CON_AddConnection 0x0001
#define WNNC_CON_CancelConnection 0x0002
#define WNNC_CON_GetConnections 0x0004
#define WNNC_CON_AutoConnect 0x0008
#define WNNC_CON_BrowseDialog 0x0010
#define WNNC_CON_RestoreConnection 0x0020
#define WNNC_PRT_OpenJob 0x0002
#define WNNC_PRT_CloseJob 0x0004
#define WNNC_PRT_HoldJob 0x0010
#define WNNC_PRT_ReleaseJob 0x0020
#define WNNC_PRT_CancelJob 0x0040
#define WNNC_PRT_SetJobCopies 0x0080
#define WNNC_PRT_WatchQueue 0x0100
#define WNNC_PRT_UnwatchQueue 0x0200
#define WNNC_PRT_LockQueueData 0x0400
#define WNNC_PRT_UnlockQueueData 0x0800
#define WNNC_PRT_ChangeMsg 0x1000
#define WNNC_PRT_AbortJob 0x2000
#define WNNC_PRT_NoArbitraryLock 0x4000
#define WNNC_PRT_WriteJob 0x8000
#define WNNC_DLG_DeviceMode 0x0001
#define WNNC_DLG_BrowseDialog 0x0002
#define WNNC_DLG_ConnectDialog 0x0004
#define WNNC_DLG_DisconnectDialog 0x0008
#define WNNC_DLG_ViewQueueDialog 0x0010
#define WNNC_DLG_PropertyDialog 0x0020
#define WNNC_DLG_ConnectionDialog 0x0040
#define WNNC_DLG_PrinterConnectDialog 0x0080
#define WNNC_DLG_SharesDialog 0x0100
#define WNNC_DLG_ShareAsDialog 0x0200
#define WNNC_ADM_GetDirectoryType 0x0001
#define WNNC_ADM_DirectoryNotify 0x0002
#define WNNC_ADM_LongNames 0x0004
#define WNNC_ADM_SetDefaultDrive 0x0008
#define WNNC_ERR_GetError 0x0001
#define WNNC_ERR_GetErrorText 0x0002
#define WNDT_NORMAL 0x0
#define WNDT_NETWORK 0x1
#define WIN30X 0x0
#define WIN31X 0x1
#define WIN311X 0x2
#define WIN95X 0x3
#define WINNTX 0x4
#define WINOTHERX 0x5
#define WIN32X 0x6
typedef LPVOID LPNETRESOURCE16;
#endif /* __WINE_WNET_H */

File diff suppressed because it is too large Load Diff

View File

@ -12,7 +12,6 @@ mciavi.spec.c
mcicda.spec.c
mciseq.spec.c
mciwave.spec.c
mpr.spec.c
ole32.spec.c
oleaut32.spec.c
olecli32.spec.c

View File

@ -13,7 +13,6 @@ SPEC_SRCS = \
dsound.spec \
gdi32.spec \
kernel32.spec \
mpr.spec \
mcianim.spec \
mciavi.spec \
mcicda.spec \