This commit is contained in:
DavidXanatos 2022-01-06 19:06:47 +01:00
parent 19d8c42f2e
commit 8eacbef11b
1 changed files with 8 additions and 6 deletions

View File

@ -679,14 +679,16 @@ BOOL Kmd_Stop_Service(
service,
SERVICE_CONTROL_STOP, &service_status)) {
if ((GetLastError() == ERROR_SERVICE_REQUEST_TIMEOUT ||
GetLastError() == ERROR_SERVICE_NOT_ACTIVE ||
GetLastError() == ERROR_PIPE_BUSY))
continue;
if (GetLastError() == ERROR_SERVICE_NOT_ACTIVE)
return TRUE;
if (!(GetLastError() == ERROR_SERVICE_REQUEST_TIMEOUT ||
GetLastError() == ERROR_PIPE_BUSY)){
Display_Error(L"ControlService Stop", 0);
return FALSE;
}
}
Sleep(500);
}