Skip to content

Commit 2f1843c

Browse files
committed
Fix comment
1 parent 42ebf28 commit 2f1843c

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
@@ -53,7 +53,7 @@ fn test_socketpair_setfl_getfl() {
5353
let res = unsafe { libc::fcntl(fds[0], libc::F_GETFL) };
5454
assert_eq!(res, new_flag);
5555

56-
// Test unset flag
56+
// Test if O_NONBLOCK flag can be unset.
5757
let res = unsafe { libc::fcntl(fds[0], libc::F_SETFL, 0) };
5858
assert_eq!(res, 0);
5959
let new_flag = libc::O_RDWR;
@@ -71,7 +71,7 @@ fn test_pipe_setfl_getfl() {
7171
let res = unsafe { libc::pipe(fds.as_mut_ptr()) };
7272
assert_eq!(res, 0);
7373

74-
// Test if both sides have O_RDWR.
74+
// Both sides should either have O_RONLY or O_WRONLY.
7575
let res = unsafe { libc::fcntl(fds[0], libc::F_GETFL) };
7676
assert_eq!(res, libc::O_RDONLY);
7777
let res = unsafe { libc::fcntl(fds[1], libc::F_GETFL) };
@@ -86,7 +86,7 @@ fn test_pipe_setfl_getfl() {
8686
let res = unsafe { libc::fcntl(fds[0], libc::F_GETFL) };
8787
assert_eq!(res, new_flag);
8888

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

0 commit comments

Comments
 (0)