mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-08-31 04:13:37 +00:00
[NTOSKRNL]
Fix SepGet*FromDescriptor, returning NULL, when the relative offset is 0. Fixes VMware tools installer. svn path=/trunk/; revision=56356
This commit is contained in:
@@ -38,6 +38,7 @@ SepGetGroupFromDescriptor(PVOID _Descriptor)
|
||||
if (Descriptor->Control & SE_SELF_RELATIVE)
|
||||
{
|
||||
SdRel = (PISECURITY_DESCRIPTOR_RELATIVE)Descriptor;
|
||||
if (!SdRel->Group) return NULL;
|
||||
return (PSID)((ULONG_PTR)Descriptor + SdRel->Group);
|
||||
}
|
||||
else
|
||||
@@ -56,6 +57,7 @@ SepGetOwnerFromDescriptor(PVOID _Descriptor)
|
||||
if (Descriptor->Control & SE_SELF_RELATIVE)
|
||||
{
|
||||
SdRel = (PISECURITY_DESCRIPTOR_RELATIVE)Descriptor;
|
||||
if (!SdRel->Owner) return NULL;
|
||||
return (PSID)((ULONG_PTR)Descriptor + SdRel->Owner);
|
||||
}
|
||||
else
|
||||
@@ -74,6 +76,7 @@ SepGetDaclFromDescriptor(PVOID _Descriptor)
|
||||
if (Descriptor->Control & SE_SELF_RELATIVE)
|
||||
{
|
||||
SdRel = (PISECURITY_DESCRIPTOR_RELATIVE)Descriptor;
|
||||
if (!SdRel->Dacl) return NULL;
|
||||
return (PACL)((ULONG_PTR)Descriptor + SdRel->Dacl);
|
||||
}
|
||||
else
|
||||
@@ -92,6 +95,7 @@ SepGetSaclFromDescriptor(PVOID _Descriptor)
|
||||
if (Descriptor->Control & SE_SELF_RELATIVE)
|
||||
{
|
||||
SdRel = (PISECURITY_DESCRIPTOR_RELATIVE)Descriptor;
|
||||
if (!SdRel->Sacl) return NULL;
|
||||
return (PACL)((ULONG_PTR)Descriptor + SdRel->Sacl);
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user