diff options
author | bors <bors@rust-lang.org> | 2021-10-23 08:51:27 +0000 |
---|---|---|
committer | bors <bors@rust-lang.org> | 2021-10-23 08:51:27 +0000 |
commit | a2693689ebe760e534c27240204ca5a27b7881cd (patch) | |
tree | d56d9adebca68b28ff6e9511edeaf7f0289d8779 | |
parent | e51d06678d7a09b65d97219e899d2c129de3ce8c (diff) | |
parent | e2638e3bcf79880a9c271da1d75b4fe832b2f019 (diff) | |
download | rust-libc-a2693689ebe760e534c27240204ca5a27b7881cd.tar.gz |
Auto merge of #2474 - NeoRaider:pidfd, r=JohnTitor
linux_like: Add CLONE_PIDFD flag
-rw-r--r-- | libc-test/build.rs | 1 | ||||
-rw-r--r-- | libc-test/semver/android.txt | 1 | ||||
-rw-r--r-- | libc-test/semver/linux.txt | 1 | ||||
-rw-r--r-- | src/unix/linux_like/android/mod.rs | 2 | ||||
-rw-r--r-- | src/unix/linux_like/linux/mod.rs | 2 |
5 files changed, 7 insertions, 0 deletions
diff --git a/libc-test/build.rs b/libc-test/build.rs index eb92b2c4ce..a161507f10 100644 --- a/libc-test/build.rs +++ b/libc-test/build.rs @@ -2654,6 +2654,7 @@ fn test_linux(target: &str) { "linux/random.h", "linux/reboot.h", "linux/rtnetlink.h", + "linux/sched.h", "linux/seccomp.h", "linux/sockios.h", "linux/uinput.h", diff --git a/libc-test/semver/android.txt b/libc-test/semver/android.txt index 9bbe6b10e1..9e70cabfec 100644 --- a/libc-test/semver/android.txt +++ b/libc-test/semver/android.txt @@ -212,6 +212,7 @@ CLONE_NEWUSER CLONE_NEWUTS CLONE_PARENT CLONE_PARENT_SETTID +CLONE_PIDFD CLONE_PTRACE CLONE_SETTLS CLONE_SIGHAND diff --git a/libc-test/semver/linux.txt b/libc-test/semver/linux.txt index 5e3ed324d1..beb9d07656 100644 --- a/libc-test/semver/linux.txt +++ b/libc-test/semver/linux.txt @@ -257,6 +257,7 @@ CLONE_NEWUSER CLONE_NEWUTS CLONE_PARENT CLONE_PARENT_SETTID +CLONE_PIDFD CLONE_PTRACE CLONE_SETTLS CLONE_SIGHAND diff --git a/src/unix/linux_like/android/mod.rs b/src/unix/linux_like/android/mod.rs index 0ef9a203f7..759eaa9af4 100644 --- a/src/unix/linux_like/android/mod.rs +++ b/src/unix/linux_like/android/mod.rs @@ -2447,6 +2447,8 @@ pub const SCHED_DEADLINE: ::c_int = 6; pub const SCHED_RESET_ON_FORK: ::c_int = 0x40000000; +pub const CLONE_PIDFD: ::c_int = 0x1000; + // bits/seek_constants.h pub const SEEK_DATA: ::c_int = 3; pub const SEEK_HOLE: ::c_int = 4; diff --git a/src/unix/linux_like/linux/mod.rs b/src/unix/linux_like/linux/mod.rs index 22bdab8b44..d0d86ac0b5 100644 --- a/src/unix/linux_like/linux/mod.rs +++ b/src/unix/linux_like/linux/mod.rs @@ -1509,6 +1509,8 @@ pub const SCHED_IDLE: ::c_int = 5; pub const SCHED_RESET_ON_FORK: ::c_int = 0x40000000; +pub const CLONE_PIDFD: ::c_int = 0x1000; + // netinet/in.h // NOTE: These are in addition to the constants defined in src/unix/mod.rs |