diff options
author | bors <bors@rust-lang.org> | 2018-12-26 17:32:06 +0000 |
---|---|---|
committer | bors <bors@rust-lang.org> | 2018-12-26 17:32:06 +0000 |
commit | 16b6c0ee83aa23633fb2eb16bfbcbe5c48cff833 (patch) | |
tree | 9da20c96912e933862eb334ae11247c62820fb96 | |
parent | a4d41775f3df6db4bbbf91c9eb59c0d78a87038c (diff) | |
parent | 63d1a8c160c15ef729db24d5e82b1af8540ca46f (diff) | |
download | rust-libc-16b6c0ee83aa23633fb2eb16bfbcbe5c48cff833.tar.gz |
Auto merge of #1186 - glaubitz:fcntl-fixes, r=alexcrichton
Define missing F_RDLCK, F_WRLCK and F_UNLCK constants on linux-mips -and s390x
These are defined in the fcntl.h glibc header on MIPS and s390x
systems on Linux but missing in the libc crate, so add them as they
are required for the file locking API in rustc.
-rw-r--r-- | src/unix/notbsd/linux/mips/mod.rs | 3 | ||||
-rw-r--r-- | src/unix/notbsd/linux/s390x.rs | 3 |
2 files changed, 6 insertions, 0 deletions
diff --git a/src/unix/notbsd/linux/mips/mod.rs b/src/unix/notbsd/linux/mips/mod.rs index b000d6df45..8809bef81e 100644 --- a/src/unix/notbsd/linux/mips/mod.rs +++ b/src/unix/notbsd/linux/mips/mod.rs @@ -537,6 +537,9 @@ pub const MAP_HUGETLB: ::c_int = 0x080000; pub const EFD_NONBLOCK: ::c_int = 0x80; +pub const F_RDLCK: ::c_int = 0; +pub const F_WRLCK: ::c_int = 1; +pub const F_UNLCK: ::c_int = 2; pub const F_GETLK: ::c_int = 14; pub const F_GETOWN: ::c_int = 23; pub const F_SETOWN: ::c_int = 24; diff --git a/src/unix/notbsd/linux/s390x.rs b/src/unix/notbsd/linux/s390x.rs index 9196f88b45..9e3814f3c5 100644 --- a/src/unix/notbsd/linux/s390x.rs +++ b/src/unix/notbsd/linux/s390x.rs @@ -791,6 +791,9 @@ pub const MAP_HUGETLB: ::c_int = 0x040000; pub const EFD_NONBLOCK: ::c_int = 0x800; +pub const F_RDLCK: ::c_int = 0; +pub const F_WRLCK: ::c_int = 1; +pub const F_UNLCK: ::c_int = 2; pub const F_GETLK: ::c_int = 5; pub const F_GETOWN: ::c_int = 9; pub const F_SETOWN: ::c_int = 8; |