mpr: Implement WNetCancelConnectionA(), WNetCancelConnectionW(), WNetCancelConnection2A().

Signed-off-by: Pierre Schweitzer <pierre@reactos.org>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Pierre Schweitzer 2016-08-02 13:22:07 +02:00 committed by Alexandre Julliard
parent 0b34924bd8
commit d2e68234b2
1 changed files with 10 additions and 8 deletions

View File

@ -1838,9 +1838,7 @@ DWORD WINAPI WNetUseConnectionA( HWND hwndOwner, NETRESOURCEA *resource,
*/ */
DWORD WINAPI WNetCancelConnectionA( LPCSTR lpName, BOOL fForce ) DWORD WINAPI WNetCancelConnectionA( LPCSTR lpName, BOOL fForce )
{ {
FIXME( "(%s, %d), stub\n", debugstr_a(lpName), fForce ); return WNetCancelConnection2A(lpName, 0, fForce);
return WN_SUCCESS;
} }
/********************************************************************* /*********************************************************************
@ -1848,9 +1846,7 @@ DWORD WINAPI WNetCancelConnectionA( LPCSTR lpName, BOOL fForce )
*/ */
DWORD WINAPI WNetCancelConnectionW( LPCWSTR lpName, BOOL fForce ) DWORD WINAPI WNetCancelConnectionW( LPCWSTR lpName, BOOL fForce )
{ {
FIXME( "(%s, %d), stub\n", debugstr_w(lpName), fForce ); return WNetCancelConnection2W(lpName, 0, fForce);
return WN_SUCCESS;
} }
/********************************************************************* /*********************************************************************
@ -1858,9 +1854,15 @@ DWORD WINAPI WNetCancelConnectionW( LPCWSTR lpName, BOOL fForce )
*/ */
DWORD WINAPI WNetCancelConnection2A( LPCSTR lpName, DWORD dwFlags, BOOL fForce ) DWORD WINAPI WNetCancelConnection2A( LPCSTR lpName, DWORD dwFlags, BOOL fForce )
{ {
FIXME( "(%s, %08X, %d), stub\n", debugstr_a(lpName), dwFlags, fForce ); DWORD ret;
WCHAR * name = strdupAtoW(lpName);
if (!name)
return ERROR_NOT_CONNECTED;
return WN_SUCCESS; ret = WNetCancelConnection2W(name, dwFlags, fForce);
HeapFree(GetProcessHeap(), 0, name);
return ret;
} }
/********************************************************************* /*********************************************************************