Skip to content

Commit 2178e3a

Browse files
committed
Clarify stdin behavior of Command::output.
Fixes #44929.
1 parent b55d290 commit 2178e3a

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/libstd/process.rs

+4-2
Original file line numberDiff line numberDiff line change
@@ -712,8 +712,10 @@ impl Command {
712712
/// Executes the command as a child process, waiting for it to finish and
713713
/// collecting all of its output.
714714
///
715-
/// By default, stdin, stdout and stderr are captured (and used to
716-
/// provide the resulting output).
715+
/// By default, stdout and stderr are captured (and used to provide the
716+
/// resulting output). Stdin is not inherited from the parent and any
717+
/// attempt by the child process to read from the stdin stream will result
718+
/// in the stream immediately closing.
717719
///
718720
/// # Examples
719721
///

0 commit comments

Comments
 (0)