From 965df8ed4f5e5878c04f646877b0e2f20bae9846 Mon Sep 17 00:00:00 2001 From: Philipp Matthias Schaefer Date: Wed, 10 Aug 2016 22:18:29 +0200 Subject: [PATCH] Add missing constants for poll() flags --- src/unix/bsd/apple/mod.rs | 5 +++++ src/unix/notbsd/linux/mips.rs | 5 +++++ src/unix/notbsd/linux/musl/mod.rs | 5 +++++ src/unix/notbsd/linux/other/mod.rs | 5 +++++ 4 files changed, 20 insertions(+) diff --git a/src/unix/bsd/apple/mod.rs b/src/unix/bsd/apple/mod.rs index 186ecb3d..50dad1f5 100644 --- a/src/unix/bsd/apple/mod.rs +++ b/src/unix/bsd/apple/mod.rs @@ -1285,6 +1285,11 @@ pub const CTL_DEBUG_NAME: ::c_int = 0; pub const CTL_DEBUG_VALUE: ::c_int = 1; pub const CTL_DEBUG_MAXID: ::c_int = 20; +pub const POLLRDNORM: ::c_short = 0x040; +pub const POLLWRNORM: ::c_short = 0x004; +pub const POLLRDBAND: ::c_short = 0x080; +pub const POLLWRBAND: ::c_short = 0x100; + pub const PRIO_DARWIN_THREAD: ::c_int = 3; pub const PRIO_DARWIN_PROCESS: ::c_int = 4; pub const PRIO_DARWIN_BG: ::c_int = 0x1000; diff --git a/src/unix/notbsd/linux/mips.rs b/src/unix/notbsd/linux/mips.rs index 6464adce..c3a1edcb 100644 --- a/src/unix/notbsd/linux/mips.rs +++ b/src/unix/notbsd/linux/mips.rs @@ -413,6 +413,11 @@ pub const SIG_SETMASK: ::c_int = 3; pub const SIG_BLOCK: ::c_int = 0x1; pub const SIG_UNBLOCK: ::c_int = 0x2; +pub const POLLRDNORM: ::c_short = 0x040; +pub const POLLWRNORM: ::c_short = 0x004; +pub const POLLRDBAND: ::c_short = 0x080; +pub const POLLWRBAND: ::c_short = 0x100; + pub const PTHREAD_STACK_MIN: ::size_t = 131072; pub const ADFS_SUPER_MAGIC: ::c_long = 0x0000adf5; diff --git a/src/unix/notbsd/linux/musl/mod.rs b/src/unix/notbsd/linux/musl/mod.rs index 78c9c824..7a0d4c43 100644 --- a/src/unix/notbsd/linux/musl/mod.rs +++ b/src/unix/notbsd/linux/musl/mod.rs @@ -153,6 +153,11 @@ pub const MADV_DONTDUMP: ::c_int = 16; pub const EPOLLWAKEUP: ::c_int = 0x20000000; +pub const POLLRDNORM: ::c_short = 0x040; +pub const POLLWRNORM: ::c_short = 0x100; +pub const POLLRDBAND: ::c_short = 0x080; +pub const POLLWRBAND: ::c_short = 0x200; + pub const MADV_HUGEPAGE: ::c_int = 14; pub const MADV_NOHUGEPAGE: ::c_int = 15; diff --git a/src/unix/notbsd/linux/other/mod.rs b/src/unix/notbsd/linux/other/mod.rs index e6d5971f..76b06a18 100644 --- a/src/unix/notbsd/linux/other/mod.rs +++ b/src/unix/notbsd/linux/other/mod.rs @@ -378,6 +378,11 @@ pub const SIG_SETMASK: ::c_int = 2; pub const SIG_BLOCK: ::c_int = 0x000000; pub const SIG_UNBLOCK: ::c_int = 0x01; +pub const POLLRDNORM: ::c_short = 0x040; +pub const POLLWRNORM: ::c_short = 0x100; +pub const POLLRDBAND: ::c_short = 0x080; +pub const POLLWRBAND: ::c_short = 0x200; + pub const FALLOC_FL_KEEP_SIZE: ::c_int = 0x01; pub const FALLOC_FL_PUNCH_HOLE: ::c_int = 0x02;