user.exe: Forward WNetGetUser16 to WNetGetUserA of mpr.dll, based on a patch from Andrew Nguyen.

This commit is contained in:
Stefan Leichter 2010-01-14 21:09:54 +01:00 committed by Alexandre Julliard
parent a657380612
commit 5ef5ead15f
4 changed files with 23 additions and 6 deletions

View File

@ -3,7 +3,7 @@ TOPOBJDIR = ../..
SRCDIR = @srcdir@ SRCDIR = @srcdir@
VPATH = @srcdir@ VPATH = @srcdir@
MODULE = user.exe16 MODULE = user.exe16
IMPORTS = user32 gdi32 kernel32 kernel ntdll IMPORTS = mpr user32 gdi32 kernel32 kernel ntdll
EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,user32.dll,--heap,65520 EXTRADLLFLAGS = -Wb,--subsystem,win16,--main-module,user32.dll,--heap,65520
EXTRARCFLAGS = -O res16 EXTRARCFLAGS = -O res16

View File

@ -30,6 +30,7 @@
#include "windef.h" #include "windef.h"
#include "winbase.h" #include "winbase.h"
#include "winnetwk.h"
#include "wine/winnet16.h" #include "wine/winnet16.h"
#include "wine/debug.h" #include "wine/debug.h"
@ -306,10 +307,26 @@ WORD WINAPI WNetGetCaps16( WORD capability )
/************************************************************************** /**************************************************************************
* WNetGetUser [USER.516] * WNetGetUser [USER.516]
*/ */
WORD WINAPI WNetGetUser16( LPCSTR lpName, LPSTR szUser, LPINT16 nBufferSize ) WORD WINAPI WNetGetUser16( LPSTR szUser, LPINT16 nBufferSize )
{ {
FIXME( "(%p, %p, %p): stub\n", lpName, szUser, nBufferSize ); DWORD lpBufferSize, ret;
return WN16_NOT_SUPPORTED;
if(!szUser || !nBufferSize) return WN16_BAD_POINTER;
lpBufferSize = *nBufferSize;
ret = WNetGetUserA( NULL, szUser, &lpBufferSize );
*nBufferSize = lpBufferSize;
switch (ret)
{
case NO_ERROR:
return WN16_SUCCESS;
case ERROR_MORE_DATA:
return WN16_MORE_DATA;
default:
FIXME("Untranslated return value %d\n", ret);
}
return ret;
} }

View File

@ -463,7 +463,7 @@
513 pascal -ret16 WNetGetCaps(word) WNetGetCaps16 513 pascal -ret16 WNetGetCaps(word) WNetGetCaps16
514 pascal -ret16 WNetDeviceMode(word) WNetDeviceMode16 514 pascal -ret16 WNetDeviceMode(word) WNetDeviceMode16
515 pascal -ret16 WNetBrowseDialog(word word ptr) WNetBrowseDialog16 515 pascal -ret16 WNetBrowseDialog(word word ptr) WNetBrowseDialog16
516 pascal -ret16 WNetGetUser(ptr ptr ptr) WNetGetUser16 516 pascal -ret16 WNetGetUser(ptr ptr) WNetGetUser16
517 pascal -ret16 WNetAddConnection(str str str) WNetAddConnection16 517 pascal -ret16 WNetAddConnection(str str str) WNetAddConnection16
518 pascal -ret16 WNetCancelConnection(str word) WNetCancelConnection16 518 pascal -ret16 WNetCancelConnection(str word) WNetCancelConnection16
519 pascal -ret16 WNetGetError(ptr) WNetGetError16 519 pascal -ret16 WNetGetError(ptr) WNetGetError16

View File

@ -199,7 +199,7 @@ WORD WINAPI WNetGetCaps16(WORD);
* Get User * Get User
*/ */
WORD WINAPI WNetGetUser16(LPCSTR,LPSTR,LPINT16); WORD WINAPI WNetGetUser16(LPSTR,LPINT16);
/* /*