Skip to content

Commit c38e528

Browse files
committed
Auto merge of #2366 - electroCutie:mremap_dontunmap, r=Amanieu
Fixes #2365 by adding the MREMAP_DONTUNMAP flag I just added the flag's value to the same file that the related flags was already in, I'm not sure where else it might need to be added for testing etc
2 parents 9221614 + 305c501 commit c38e528

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

libc-test/build.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2795,6 +2795,9 @@ fn test_linux(target: &str) {
27952795
// Require Linux kernel 5.6:
27962796
"VMADDR_CID_LOCAL" => true,
27972797

2798+
// Requires Linux kernel 5.7:
2799+
"MREMAP_DONTUNMAP" => true,
2800+
27982801
// IPPROTO_MAX was increased in 5.6 for IPPROTO_MPTCP:
27992802
| "IPPROTO_MAX"
28002803
| "IPPROTO_MPTCP" => true,

src/unix/linux_like/linux/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1598,6 +1598,7 @@ cfg_if! {
15981598

15991599
pub const MREMAP_MAYMOVE: ::c_int = 1;
16001600
pub const MREMAP_FIXED: ::c_int = 2;
1601+
pub const MREMAP_DONTUNMAP: ::c_int = 4;
16011602

16021603
pub const PR_SET_PDEATHSIG: ::c_int = 1;
16031604
pub const PR_GET_PDEATHSIG: ::c_int = 2;

0 commit comments

Comments
 (0)