mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Update AdjustTokenPrivileges PInvoke usage
Refactored the AdjustTokenPrivileges call to use null for the previous state and an out variable for the return length, improving compatibility with the PInvoke signature and aligning with recommended usage.
This commit is contained in:
parent
97d7eab1a7
commit
d4f472a64e
1 changed files with 1 additions and 1 deletions
|
|
@ -175,7 +175,7 @@ namespace Flow.Launcher.Plugin.Sys
|
|||
Privileges = new() { e0 = new LUID_AND_ATTRIBUTES { Luid = luid, Attributes = TOKEN_PRIVILEGES_ATTRIBUTES.SE_PRIVILEGE_ENABLED } }
|
||||
};
|
||||
|
||||
if (!PInvoke.AdjustTokenPrivileges(tokenHandle, false, &privileges, 0, null, null))
|
||||
if (!PInvoke.AdjustTokenPrivileges(tokenHandle, false, &privileges, null, out var _))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue