mirror of
https://github.com/reactos/reactos.git
synced 2025-05-06 18:31:26 +00:00
[NTOS:OB] Correctly check SeSinglePrivilegeCheck() return value (#1323)
SeSinglePrivilegeCheck() returns a BOOLEAN, not a NTSTATUS. CORE-14271
This commit is contained in:
parent
1e05f9cc32
commit
0483a5a380
1 changed files with 4 additions and 3 deletions
|
@ -1427,9 +1427,10 @@ NtMakePermanentObject(IN HANDLE ObjectHandle)
|
||||||
PAGED_CODE();
|
PAGED_CODE();
|
||||||
|
|
||||||
/* Make sure that the caller has SeCreatePermanentPrivilege */
|
/* Make sure that the caller has SeCreatePermanentPrivilege */
|
||||||
Status = SeSinglePrivilegeCheck(SeCreatePermanentPrivilege,
|
if (!SeSinglePrivilegeCheck(SeCreatePermanentPrivilege, PreviousMode))
|
||||||
PreviousMode);
|
{
|
||||||
if (!NT_SUCCESS(Status)) return STATUS_PRIVILEGE_NOT_HELD;
|
return STATUS_PRIVILEGE_NOT_HELD;
|
||||||
|
}
|
||||||
|
|
||||||
/* Reference the object */
|
/* Reference the object */
|
||||||
Status = ObReferenceObjectByHandle(ObjectHandle,
|
Status = ObReferenceObjectByHandle(ObjectHandle,
|
||||||
|
|
Loading…
Reference in a new issue