Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Handle close on redirected pipe, without getting an EOF first
This commit handles getting a close on a pipe used as a read redirect target on a pipe without ever receiving an EOF. This seems to happen on Linux when redirecting to a pseudo-TTY. When the slave TTY is closed, the master half gets an I/O error, triggering connection_lost to be called with an exception rather than eof_received. This prevented calls to drain() from properly unblocking, since the redirect was not properly cleaned up. Thanks go to GitHub user xuoguoto who helped to provide sample scripts showing the problem and ran multiple tests collecting data to help track this down!
- Loading branch information