forked from JetBrains/pty4j
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a getChildProcessId method to WinPty and WinPtyProcess.
Ensure that the process handle stays open until both of these conditions are met: 1. The process has exited. 2. We have disconnected from the agent, by closing the winpty_t object. For consistency with the getChildProcessId method in pty4j-0.6, and to reduce the possibility of a race condition, have getChildProcessId return -1 as soon as the WinPty object is closed, even if the process is still running (for a brief moment). Rename Reaper to WaitForExitThread. I think the "reaper" on Unix is so-named because it cleans up zombie processes. The WinPty equivalent instead leaves a zombie process handle/PID alive while until the WinPty object is closed.
- Loading branch information
Showing
2 changed files
with
54 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters