Skip to content

Commit

Permalink
Typo
Browse files Browse the repository at this point in the history
  • Loading branch information
tiif committed Dec 23, 2024
1 parent e252bc6 commit a0b952e
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ fn main() {
});
let thread2 = thread::spawn(move || {
// Close the socketpair fd while thread1 is blocking on it.
assert_eq!(unsafe { libc::close(fds[0]) }, 0);
assert_eq!(unsafe { libc::close(fds[1]) }, 0);
let data = "abc".as_bytes().as_ptr();
let res = unsafe { libc::write(fds[0], data as *const libc::c_void, 3) };
// This will fail because we can't write anything if the peer_fd is closed.
Expand Down

0 comments on commit a0b952e

Please sign in to comment.