Update proc.c

Restores the BlockSoftwareUpdaters setting.
This commit is contained in:
offhub 2024-07-02 11:52:30 +03:00
parent 1c003ac73d
commit b19b7eb3ab
No known key found for this signature in database
GPG Key ID: 7B12A8941851DA59
1 changed files with 7 additions and 6 deletions

View File

@ -1653,14 +1653,15 @@ _FX BOOL Proc_AlternateCreateProcess(
void *lpCurrentDirectory, LPPROCESS_INFORMATION lpProcessInformation, void *lpCurrentDirectory, LPPROCESS_INFORMATION lpProcessInformation,
BOOL *ReturnValue) BOOL *ReturnValue)
{ {
//if (SbieApi_QueryConfBool(NULL, L"BlockSoftwareUpdaters", TRUE)) if (SbieApi_QueryConfBool(NULL, L"BlockSoftwareUpdaters", TRUE)) {
if (Proc_IsSoftwareUpdateW(lpApplicationName ? lpApplicationName : lpCommandLine)) { if (Proc_IsSoftwareUpdateW(lpApplicationName ? lpApplicationName : lpCommandLine)) {
SetLastError(ERROR_ACCESS_DENIED); SetLastError(ERROR_ACCESS_DENIED);
*ReturnValue = FALSE; *ReturnValue = FALSE;
SbieApi_MonitorPutMsg(MONITOR_OTHER, L"Blocked start of an updater"); SbieApi_MonitorPutMsg(MONITOR_OTHER, L"Blocked start of an updater");
return TRUE; // exit CreateProcessInternal return TRUE; // exit CreateProcessInternal
}
} }
#ifndef _WIN64 #ifndef _WIN64