We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8b27976 commit 12c6c53Copy full SHA for 12c6c53
user/src/bin/pipetest.rs
@@ -23,6 +23,8 @@ pub fn main() -> i32 {
23
close(pipe_fd[1]);
24
let mut buffer = [0u8; 32];
25
let len_read = read(pipe_fd[0], &mut buffer) as usize;
26
+ // close read_end
27
+ close(pipe_fd[0]);
28
assert_eq!(core::str::from_utf8(&buffer[..len_read]).unwrap(), STR);
29
println!("Read OK, child process exited!");
30
0
0 commit comments