This commit is contained in:
Vichingo455
2025-03-23 15:26:15 +01:00
parent cacf40b6cd
commit ad8366918e
72 changed files with 10255 additions and 2 deletions

12
launcher/SelfElevate.c Normal file
View File

@@ -0,0 +1,12 @@
#include "SelfElevate.h"
#include <windows.h>
#include "Exec.h"
#include "VersionInfo.h"
HRESULT SelfElevate(LPWSTR args, LPDWORD code) {
LPWSTR fileName;
GetOwnFileName(&fileName);
HRESULT hr = Exec(L"runas", fileName, args, NULL, SW_SHOWDEFAULT, TRUE, code);
LocalFree(fileName);
return hr;
}