advapi32: Start non-interactive services in a separate window station.
This commit is contained in:
parent
a32873bfcc
commit
7593fac632
|
@ -1578,6 +1578,12 @@ static DWORD service_start_process(struct sc_service *hsvc, LPDWORD ppid)
|
|||
handles[0] = service_get_event_handle( hsvc->name );
|
||||
ZeroMemory(&si, sizeof(STARTUPINFOW));
|
||||
si.cb = sizeof(STARTUPINFOW);
|
||||
if (!(svc_type & SERVICE_INTERACTIVE_PROCESS))
|
||||
{
|
||||
static WCHAR desktopW[] = {'_','_','w','i','n','e','s','e','r','v','i','c','e','_','w','i','n','s','t','a','t','i','o','n','\\','D','e','f','a','u','l','t',0};
|
||||
si.lpDesktop = desktopW;
|
||||
}
|
||||
|
||||
r = CreateProcessW(NULL, path, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi);
|
||||
if (r)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue