diff --git a/dlls/ntdll/nt.c b/dlls/ntdll/nt.c index 228dc1218c6..24309dbf452 100644 --- a/dlls/ntdll/nt.c +++ b/dlls/ntdll/nt.c @@ -737,3 +737,13 @@ NTSTATUS WINAPI NtAllocateLocallyUniqueId(PLUID Luid) return STATUS_SUCCESS; } + +/****************************************************************************** + * VerSetConditionMask (NTDLL.@) + */ +ULONGLONG WINAPI VerSetConditionMask( ULONGLONG dwlConditionMask, DWORD dwTypeBitMask, + BYTE dwConditionMask) +{ + FIXME("%llx %lu %u\n", dwlConditionMask, dwTypeBitMask, dwConditionMask); + return dwlConditionMask; +} diff --git a/dlls/ntdll/ntdll.spec b/dlls/ntdll/ntdll.spec index 2914d24674f..77b509f16b4 100644 --- a/dlls/ntdll/ntdll.spec +++ b/dlls/ntdll/ntdll.spec @@ -310,7 +310,7 @@ debug_channels (atom cdrom console debug delayhlp dll dosfs dosmem file fixup @ stub RtlConvertExclusiveToShared @ stdcall -ret64 RtlConvertLongToLargeInteger(long) RtlConvertLongToLargeInteger @ stub RtlConvertSharedToExclusive -@ stdcall RtlConvertSidToUnicodeString(ptr ptr)RtlConvertSidToUnicodeString +@ stdcall RtlConvertSidToUnicodeString(ptr ptr long) RtlConvertSidToUnicodeString @ stub RtlConvertUiListToApiList @ stdcall -ret64 RtlConvertUlongToLargeInteger(long) RtlConvertUlongToLargeInteger @ stub RtlCopyLuid @@ -1013,6 +1013,7 @@ debug_channels (atom cdrom console debug delayhlp dll dosfs dosmem file fixup @ stub RtlCreatePropertySet @ stub RtlSetPropertySetClassId @ stdcall NtPowerInformation(long long long long long) NtPowerInformation +@ stdcall -ret64 VerSetConditionMask(long long long long) VerSetConditionMask ################## # Wine extensions diff --git a/dlls/ntdll/sec.c b/dlls/ntdll/sec.c index 37c79a15f61..2d026b5dc66 100644 --- a/dlls/ntdll/sec.c +++ b/dlls/ntdll/sec.c @@ -23,6 +23,9 @@ #include #include #include +#include +#include + #include "windef.h" #include "winbase.h" #include "wine/exception.h" @@ -721,23 +724,29 @@ NTSTATUS WINAPI RtlGetControlSecurityDescriptor( /****************************************************************************** * RtlConvertSidToUnicodeString (NTDLL.@) + * + * The returned SID is used to access the USER registry hive usually + * + * the native function returns something like + * "S-1-5-21-0000000000-000000000-0000000000-500"; */ NTSTATUS WINAPI RtlConvertSidToUnicodeString( - PUNICODE_STRING UnicodeSID, - PSID *pSid) + PUNICODE_STRING String, + PSID Sid, + BOOLEAN AllocateString) { -/* LPSTR GenSID = "S-1-5-21-0000000000-000000000-0000000000-500"; */ - - LPSTR GenSID = ".Default"; /* usually the returned SID is used to */ - /* access "\\REGISTRY\\USER\\.DEFAULT" */ - + const char *p; + NTSTATUS status; ANSI_STRING AnsiStr; - FIXME("(%p %p)\n", UnicodeSID, pSid); - if (UnicodeSID) - TRACE("%p() (%u %u)\n", - UnicodeSID->Buffer, UnicodeSID->Length, UnicodeSID->MaximumLength); + struct passwd *pwd = getpwuid( getuid() ); + p = (pwd) ? pwd->pw_name : ".Default"; - RtlInitAnsiString(&AnsiStr, GenSID); - return RtlAnsiStringToUnicodeString(UnicodeSID, &AnsiStr, TRUE); + FIXME("(%p %p %u)\n", String, Sid, AllocateString); + + RtlInitAnsiString(&AnsiStr, p); + status = RtlAnsiStringToUnicodeString(String, &AnsiStr, AllocateString); + + TRACE("%s (%u %u)\n",debugstr_w(String->Buffer),String->Length,String->MaximumLength); + return status; }