Skip to content

Commit a7ed890

Browse files
committed
Fix comment
1 parent 3c76582 commit a7ed890

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/pass-dep/libc/libc-fs-with-isolation.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ fn test_socketpair_setfl_getfl() {
5757
let res = unsafe { libc::fcntl(fds[0], libc::F_GETFL) };
5858
assert_eq!(res, new_flag);
5959

60-
// Test unset flag
60+
// Test if O_NONBLOCK flag can be unset.
6161
let res = unsafe { libc::fcntl(fds[0], libc::F_SETFL, 0) };
6262
assert_eq!(res, 0);
6363
let new_flag = libc::O_RDWR;
@@ -75,7 +75,7 @@ fn test_pipe_setfl_getfl() {
7575
let res = unsafe { libc::pipe(fds.as_mut_ptr()) };
7676
assert_eq!(res, 0);
7777

78-
// Test if both sides have O_RDWR.
78+
// Both sides should either have O_RONLY or O_WRONLY.
7979
let res = unsafe { libc::fcntl(fds[0], libc::F_GETFL) };
8080
assert_eq!(res, libc::O_RDONLY);
8181
let res = unsafe { libc::fcntl(fds[1], libc::F_GETFL) };
@@ -90,7 +90,7 @@ fn test_pipe_setfl_getfl() {
9090
let res = unsafe { libc::fcntl(fds[0], libc::F_GETFL) };
9191
assert_eq!(res, new_flag);
9292

93-
// Test unset flag.
93+
// Test if O_NONBLOCK flag can be unset.
9494
let res = unsafe { libc::fcntl(fds[0], libc::F_SETFL, 0) };
9595
assert_eq!(res, 0);
9696
let new_flag = libc::O_RDONLY;

0 commit comments

Comments
 (0)