Commit 5ef5ead1 authored by Stefan Leichter's avatar Stefan Leichter Committed by Alexandre Julliard

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

parent a6573806
...@@ -3,7 +3,7 @@ TOPOBJDIR = ../.. ...@@ -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
......
...@@ -30,6 +30,7 @@ ...@@ -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 ) ...@@ -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;
} }
......
...@@ -463,7 +463,7 @@ ...@@ -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
......
...@@ -199,7 +199,7 @@ WORD WINAPI WNetGetCaps16(WORD); ...@@ -199,7 +199,7 @@ WORD WINAPI WNetGetCaps16(WORD);
* Get User * Get User
*/ */
WORD WINAPI WNetGetUser16(LPCSTR,LPSTR,LPINT16); WORD WINAPI WNetGetUser16(LPSTR,LPINT16);
/* /*
......
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