File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -174,9 +174,12 @@ impl<'s> RemoteChild<'s> {
174
174
// and cause the remote process to block forever.
175
175
let ( stdout, stderr) = try_join ! ( stdout_read, stderr_read) ?;
176
176
Ok ( Output {
177
- // Once self.wait().await is done, the connection to the multiplex
178
- // server will also be dropped and the server will stop sending
179
- // data to stdout/stderr.
177
+ // The self.wait() future terminates the stdout and stderr futures
178
+ // when it resolves, even if there may still be more data arriving
179
+ // from the server.
180
+ //
181
+ // Therefore, we wait for them first, and only once they're complete
182
+ // do we wait for the process to have terminated.
180
183
status : self . wait ( ) . await ?,
181
184
stdout,
182
185
stderr,
You can’t perform that action at this time.
0 commit comments