Skip to content

Commit 7277138

Browse files
committed
Add F_SEAL_FUTURE_WRITE on Linux/Android
This was added in Linux 5.1 and will only show up in the next glibc release, thus skip in tests.
1 parent 48193e8 commit 7277138

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

libc-test/build.rs

+5
Original file line numberDiff line numberDiff line change
@@ -2283,6 +2283,7 @@ fn test_linux(target: &str) {
22832283

22842284
// FIXME: conflicts with glibc headers and is tested in
22852285
// `linux_termios.rs` below:
2286+
22862287
"BOTHER" => true,
22872288

22882289
// FIXME: on musl the pthread types are defined a little differently
@@ -2293,6 +2294,10 @@ fn test_linux(target: &str) {
22932294
t if mips32_musl && t.starts_with("IFF") => true,
22942295
"MFD_HUGETLB" | "AF_XDP" | "PF_XDP" if mips32_musl => true,
22952296

2297+
// FIXME: added in Linux 5.1 but not yet in glibc or musl. Enable in linux_fcntl tests
2298+
// once available.
2299+
"F_SEAL_FUTURE_WRITE" => true,
2300+
22962301
_ => false,
22972302
}
22982303
});

src/unix/notbsd/linux/mod.rs

+2
Original file line numberDiff line numberDiff line change
@@ -1050,6 +1050,8 @@ pub const F_TEST: ::c_int = 3;
10501050
pub const F_TLOCK: ::c_int = 2;
10511051
pub const F_ULOCK: ::c_int = 0;
10521052

1053+
pub const F_SEAL_FUTURE_WRITE: ::c_int = 0x0010;
1054+
10531055
pub const IFF_LOWER_UP: ::c_int = 0x10000;
10541056
pub const IFF_DORMANT: ::c_int = 0x20000;
10551057
pub const IFF_ECHO: ::c_int = 0x40000;

0 commit comments

Comments
 (0)