X-Git-Url: http://git.iain.cx/?a=blobdiff_plain;f=service.cpp;h=284b5ec206b0f0a31c00a8a51fbcc6cdf4805205;hb=54438652fac1f4f8dc6120bbfa8aac766aa656d3;hp=ee60c1072fa7f0cd36712db4489f9bf09f9270ed;hpb=ba4831e5eb179e415282a957604f039bceb4804f;p=nssm.git diff --git a/service.cpp b/service.cpp index ee60c10..284b5ec 100644 --- a/service.cpp +++ b/service.cpp @@ -1530,7 +1530,6 @@ int start_service(nssm_service_t *service) { bool inherit_handles = false; if (si.dwFlags & STARTF_USESTDHANDLES) inherit_handles = true; unsigned long flags = service->priority & priority_mask(); - if (service->stdin_pipe) flags |= DETACHED_PROCESS; if (service->affinity) flags |= CREATE_SUSPENDED; if (! CreateProcess(0, cmd, 0, 0, inherit_handles, flags, 0, service->dir, &si, &pi)) { unsigned long exitcode = 3; @@ -1620,10 +1619,6 @@ int stop_service(nssm_service_t *service, unsigned long exitcode, bool graceful, UnregisterWait(service->wait_handle); service->wait_handle = 0; } - if (service->stdin_pipe) { - CloseHandle(service->stdin_pipe); - service->stdin_pipe = 0; - } service->rotate_stdout_online = service->rotate_stderr_online = NSSM_ROTATE_OFFLINE;