mirror of
https://github.com/Ylianst/MeshAgent
synced 2025-12-21 10:43:36 +00:00
1. Fixed detached processes on Windows
2. Updated service-manager on Windows to add an uninstaller into Program Manager 3. Updated service-manager on Windows to try to delay spawn a process to delete a service, which is required if the service to be uninstalled is the currently running process.
This commit is contained in:
@@ -792,7 +792,7 @@ ILibProcessPipe_Process ILibProcessPipe_Manager_SpawnProcessEx4(ILibProcessPipe_
|
||||
|
||||
|
||||
if (spawnType != ILibProcessPipe_SpawnTypes_SPECIFIED_USER && spawnType != ILibProcessPipe_SpawnTypes_DEFAULT && (sessionId = WTSGetActiveConsoleSessionId()) == 0xFFFFFFFF) { return(NULL); } // No session attached to console, but requested to execute as logged in user
|
||||
if (spawnType != ILibProcessPipe_SpawnTypes_DEFAULT)
|
||||
if (spawnType != ILibProcessPipe_SpawnTypes_DEFAULT && spawnType != ILibProcessPipe_SpawnTypes_DETACHED)
|
||||
{
|
||||
procHandle = GetCurrentProcess();
|
||||
if (OpenProcessToken(procHandle, TOKEN_DUPLICATE, &token) == 0) { ILIBMARKPOSITION(2); return(NULL); }
|
||||
|
||||
Reference in New Issue
Block a user