[SRVSVC][WKSSVC] Server and workstation service set their service bit when they are running

This commit is contained in:
Eric Kohl 2018-05-01 16:37:48 +02:00
parent 1362983bb7
commit 027904b441
4 changed files with 14 additions and 0 deletions

View file

@ -9,6 +9,7 @@
#include <winbase.h>
#include <winreg.h>
#include <winsvc.h>
#include <lmserver.h>
#include <srvsvc_s.h>

View file

@ -127,6 +127,12 @@ ServiceInit(VOID)
else
CloseHandle(hThread);
/* Report a running server service */
SetServiceBits(ServiceStatusHandle,
SV_TYPE_SERVER,
TRUE,
TRUE);
return ERROR_SUCCESS;
}

View file

@ -9,6 +9,7 @@
#include <winbase.h>
#include <winreg.h>
#include <winsvc.h>
#include <lmserver.h>
#include <wkssvc_s.h>

View file

@ -127,6 +127,12 @@ ServiceInit(VOID)
else
CloseHandle(hThread);
/* Report a running workstation service */
SetServiceBits(ServiceStatusHandle,
SV_TYPE_WORKSTATION,
TRUE,
TRUE);
return ERROR_SUCCESS;
}