mirror of
https://github.com/reactos/reactos.git
synced 2025-01-04 21:38:43 +00:00
Autosyncing with Wine HEAD
svn path=/trunk/; revision=31784
This commit is contained in:
parent
3127d9aeb9
commit
410e3f4d4a
3 changed files with 36 additions and 5 deletions
|
@ -58,10 +58,6 @@ struct sam_user
|
||||||
LPWSTR user_logon_script_path;
|
LPWSTR user_logon_script_path;
|
||||||
};
|
};
|
||||||
|
|
||||||
static const WCHAR sAdminUserName[] = {'A','d','m','i','n','i','s','t','r','a','t',
|
|
||||||
'o','r',0};
|
|
||||||
static const WCHAR sGuestUserName[] = {'G','u','e','s','t',0};
|
|
||||||
|
|
||||||
static struct list user_list = LIST_INIT( user_list );
|
static struct list user_list = LIST_INIT( user_list );
|
||||||
|
|
||||||
BOOL NETAPI_IsLocalComputer(LPCWSTR ServerName);
|
BOOL NETAPI_IsLocalComputer(LPCWSTR ServerName);
|
||||||
|
@ -604,7 +600,7 @@ NetQueryDisplayInformation(
|
||||||
NetApiBufferAllocate(dwSize +
|
NetApiBufferAllocate(dwSize +
|
||||||
admin_size - sizeof(NET_DISPLAY_USER) +
|
admin_size - sizeof(NET_DISPLAY_USER) +
|
||||||
guest_size - sizeof(NET_DISPLAY_USER),
|
guest_size - sizeof(NET_DISPLAY_USER),
|
||||||
(LPVOID *) SortedBuffer);
|
SortedBuffer);
|
||||||
inf = (PNET_DISPLAY_USER) *SortedBuffer;
|
inf = (PNET_DISPLAY_USER) *SortedBuffer;
|
||||||
str = (LPWSTR) ((PBYTE) inf + sizeof(NET_DISPLAY_USER) * records);
|
str = (LPWSTR) ((PBYTE) inf + sizeof(NET_DISPLAY_USER) * records);
|
||||||
inf->usri1_name = str;
|
inf->usri1_name = str;
|
||||||
|
|
|
@ -166,6 +166,39 @@ NET_API_STATUS WINAPI NetLocalGroupGetMembers(
|
||||||
FIXME("(%s %s %d %p %d, %p %p %p) stub!\n", debugstr_w(servername),
|
FIXME("(%s %s %d %p %d, %p %p %p) stub!\n", debugstr_w(servername),
|
||||||
debugstr_w(localgroupname), level, bufptr, prefmaxlen, entriesread,
|
debugstr_w(localgroupname), level, bufptr, prefmaxlen, entriesread,
|
||||||
totalentries, resumehandle);
|
totalentries, resumehandle);
|
||||||
|
|
||||||
|
if (level == 3)
|
||||||
|
{
|
||||||
|
WCHAR userName[MAX_COMPUTERNAME_LENGTH + 1];
|
||||||
|
DWORD userNameLen;
|
||||||
|
DWORD len,needlen;
|
||||||
|
PLOCALGROUP_MEMBERS_INFO_3 ptr;
|
||||||
|
|
||||||
|
/* still a stub, current user is belonging to all groups */
|
||||||
|
|
||||||
|
*totalentries = 1;
|
||||||
|
*entriesread = 0;
|
||||||
|
|
||||||
|
userNameLen = MAX_COMPUTERNAME_LENGTH + 1;
|
||||||
|
GetUserNameW(userName,&userNameLen);
|
||||||
|
needlen = sizeof(LOCALGROUP_MEMBERS_INFO_3) +
|
||||||
|
(userNameLen+2) * sizeof(WCHAR);
|
||||||
|
if (prefmaxlen != MAX_PREFERRED_LENGTH)
|
||||||
|
len = min(prefmaxlen,needlen);
|
||||||
|
else
|
||||||
|
len = needlen;
|
||||||
|
|
||||||
|
NetApiBufferAllocate(len, (LPVOID *) bufptr);
|
||||||
|
if (len < needlen)
|
||||||
|
return ERROR_MORE_DATA;
|
||||||
|
|
||||||
|
ptr = (PLOCALGROUP_MEMBERS_INFO_3)*bufptr;
|
||||||
|
ptr->lgrmi3_domainandname = (LPWSTR)(*bufptr+sizeof(LOCALGROUP_MEMBERS_INFO_3));
|
||||||
|
lstrcpyW(ptr->lgrmi3_domainandname,userName);
|
||||||
|
|
||||||
|
*entriesread = 1;
|
||||||
|
}
|
||||||
|
|
||||||
return NERR_Success;
|
return NERR_Success;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
<?xml version="1.0"?>
|
<?xml version="1.0"?>
|
||||||
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
|
<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
|
||||||
|
<group>
|
||||||
<module name="netapi32" type="win32dll" baseaddress="${BASEADDRESS_NETAPI32}" installbase="system32" installname="netapi32.dll" allowwarnings="true">
|
<module name="netapi32" type="win32dll" baseaddress="${BASEADDRESS_NETAPI32}" installbase="system32" installname="netapi32.dll" allowwarnings="true">
|
||||||
<importlibrary definition="netapi32.spec.def" />
|
<importlibrary definition="netapi32.spec.def" />
|
||||||
<include base="netapi32">.</include>
|
<include base="netapi32">.</include>
|
||||||
|
@ -27,3 +28,4 @@
|
||||||
<file>wksta.c</file>
|
<file>wksta.c</file>
|
||||||
<file>netapi32.spec</file>
|
<file>netapi32.spec</file>
|
||||||
</module>
|
</module>
|
||||||
|
</group>
|
||||||
|
|
Loading…
Reference in a new issue