Auto merge of #802 - Mic92:setfsuid, r=alexcrichton

add setfsgid/setfsuid on Linux
This commit is contained in:
bors 2017-10-19 14:37:21 +00:00
commit 2172bb4bab
2 changed files with 4 additions and 1 deletions

View File

@ -190,7 +190,6 @@ fn main() {
cfg.header("sys/msg.h");
cfg.header("sys/shm.h");
cfg.header("sys/user.h");
cfg.header("sys/fsuid.h");
cfg.header("sys/timerfd.h");
cfg.header("shadow.h");
if !emscripten {
@ -241,6 +240,8 @@ fn main() {
}
if linux || android {
cfg.header("sys/fsuid.h");
// DCCP support
if !uclibc && !musl && !emscripten {
cfg.header("linux/dccp.h");

View File

@ -1050,6 +1050,8 @@ extern {
in_fd: ::c_int,
offset: *mut off_t,
count: ::size_t) -> ::ssize_t;
pub fn setfsgid(gid: ::gid_t) -> ::c_int;
pub fn setfsuid(uid: ::uid_t) -> ::c_int;
pub fn sigsuspend(mask: *const ::sigset_t) -> ::c_int;
#[cfg_attr(target_os = "solaris", link_name = "__posix_getgrgid_r")]
pub fn getgrgid_r(uid: ::uid_t,