Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
copyutil: closing the local end of pipes after processes starts
CopyTask is is using ReceivingChannels and SendingChannels which are a list of pipes created by CopyTask and those pipes are being send to a list of subprocesses so the main task can communicate with them. in one dtest that delibratily make once of those child process to break and exit, from time to time we see it getting stuck forever. the reason is the CopyTask process is hanging on `recv` call on one of those pipes, since pipes are copy into the child processes there's one fd open on CopyTask and one fd open on child process when the child process closes the fd, `recv()` doesn't raise EOF since there an open fd that might still send in data. so we need to close the local pipes on CopyTask after all child processes are started Fixes: #37
- Loading branch information