diff options
author | luozijun <gnulinux@126.com> | 2017-11-09 16:54:03 +0800 |
---|---|---|
committer | luozijun <gnulinux@126.com> | 2017-11-09 16:54:03 +0800 |
commit | 9108f5b51dffd44dce3b855d37eb677751d8dd4e (patch) | |
tree | 47f926021837e5736404da5fb26078be0a4bc934 /src/unix/haiku | |
parent | 86b4281c9882a4d18b946c0bec772d146afa4733 (diff) | |
download | rust-libc-9108f5b51dffd44dce3b855d37eb677751d8dd4e.tar.gz |
Add network interface flag constants for all platforms
Add network interface flag constants for all platforms.
Diffstat (limited to 'src/unix/haiku')
-rw-r--r-- | src/unix/haiku/mod.rs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/unix/haiku/mod.rs b/src/unix/haiku/mod.rs index 2b05e8ef87..ebb20720b3 100644 --- a/src/unix/haiku/mod.rs +++ b/src/unix/haiku/mod.rs @@ -606,7 +606,20 @@ pub const MADV_RANDOM: ::c_int = 3; pub const MADV_WILLNEED: ::c_int = 4; pub const MADV_DONTNEED: ::c_int = 5; +// https://github.com/haiku/haiku/blob/master/headers/posix/net/if.h#L80 +pub const IFF_UP: ::c_int = 0x0001; +pub const IFF_BROADCAST: ::c_int = 0x0002; // valid broadcast address pub const IFF_LOOPBACK: ::c_int = 0x0008; +pub const IFF_POINTOPOINT: ::c_int = 0x0010; // point-to-point link +pub const IFF_NOARP: ::c_int = 0x0040; // no address resolution +pub const IFF_AUTOUP: ::c_int = 0x0080; // auto dial +pub const IFF_PROMISC: ::c_int = 0x0100; // receive all packets +pub const IFF_ALLMULTI: ::c_int = 0x0200; // receive all multicast packets +pub const IFF_SIMPLEX: ::c_int = 0x0800; // doesn't receive own transmissions +pub const IFF_LINK: ::c_int = 0x1000; // has link +pub const IFF_AUTO_CONFIGURED: ::c_int = 0x2000; +pub const IFF_CONFIGURING: ::c_int = 0x4000; +pub const IFF_MULTICAST: ::c_int = 0x8000; // supports multicast pub const AF_UNSEC: ::c_int = 0; pub const AF_INET: ::c_int = 1; |