You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by ma...@apache.org on 2022/05/03 10:59:52 UTC

[commons-daemon] 03/03: Add comments

This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-daemon.git

commit 5e6b64401417b63b0de125e2489159678af8412e
Author: Jean-Frederic Clere <jf...@gmail.com>
AuthorDate: Sun May 1 10:47:25 2022 +0200

    Add comments
---
 src/native/windows/src/rprocess.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/native/windows/src/rprocess.c b/src/native/windows/src/rprocess.c
index 4ce2ef1..dec464c 100644
--- a/src/native/windows/src/rprocess.c
+++ b/src/native/windows/src/rprocess.c
@@ -373,6 +373,7 @@ static BOOL __apxProcessClose(APXHANDLE hProcess)
     lpProc = APXHANDLE_DATA(hProcess);
     CHECK_IF_ACTIVE(lpProc);
 
+    /* dry run to get debug information */
     __apxProcessTerminateChild(lpProc->stProcInfo.dwProcessId, TRUE);
     /* Try to close the child's stdin first */
     SAFE_CLOSE_HANDLE(lpProc->hChildInpWr);
@@ -409,7 +410,9 @@ static BOOL __apxProcessClose(APXHANDLE hProcess)
                 if (!GetExitCodeProcess(lpProc->stProcInfo.hProcess, &status) ||
                                 (status != STILL_ACTIVE)) {
                      apxLogWrite(APXLOG_MARK_DEBUG "__apxProcessClose Gone(thread exit)");
-                     // We are here when the service starts something like wildfly via standalone.sh and wildfly doesn't terminate cleanly, 
+                     /* We are here when the service starts something like wildfly via standalone.sh and wildfly doesn't terminate cleanly, 
+                      * dry run is FALSE: we kill all the process of the process tree
+                      */
                      __apxProcessTerminateChild(lpProc->stProcInfo.dwProcessId, FALSE);
                 }