-
Notifications
You must be signed in to change notification settings - Fork 666
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update InterfaceFlags
#853
Conversation
Looks like Android is failing. Are these flags available on Android? If so, they should be added to |
i will check android later. |
Needs an entry in the CHANGELOG. Otherwise, LGTM. |
src/net/if_.rs
Outdated
@@ -215,6 +215,15 @@ libc_bitflags!( | |||
/// Don't exchange routing info. | |||
#[cfg(any(target_os = "solaris"))] | |||
IFF_NORTEXCH; | |||
/// Do not provide packet information | |||
#[cfg(any(target_os = "linux"))] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove any(
src/net/if_.rs
Outdated
#[cfg(any(target_os = "linux"))] | ||
IFF_NO_PI as i32; | ||
/// TUN device (no Ethernet headers) | ||
#[cfg(any(target_os = "linux"))] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove any(
src/net/if_.rs
Outdated
#[cfg(any(target_os = "linux"))] | ||
IFF_TUN as i32; | ||
/// TAP device | ||
#[cfg(any(target_os = "linux"))] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove any(
src/net/if_.rs
Outdated
@@ -215,6 +215,15 @@ libc_bitflags!( | |||
/// Don't exchange routing info. | |||
#[cfg(any(target_os = "solaris"))] | |||
IFF_NORTEXCH; | |||
/// Do not provide packet information | |||
#[cfg(any(target_os = "linux"))] | |||
IFF_NO_PI as i32; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be c_int
for all 3 of these to match the enum declaration.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's done
2075aa7
to
147f63a
Compare
upstream PR: rust-lang/libc#916 |
21d30e2
to
b7868e5
Compare
@Susurrus ping ... |
Please add a link to the PR in the CHANGELOG like the other entries do. |
Updated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This last change than LGTM
CHANGELOG.md
Outdated
@@ -10,6 +10,8 @@ This project adheres to [Semantic Versioning](http://semver.org/). | |||
### Changed | |||
- Display and Debug for SysControlAddr now includes all fields. | |||
([#837](https://github.com/nix-rust/nix/pull/837)) | |||
- `nix::net::if_::InterfaceFlags` now support `IFF_NO_PI/IFF_TUN/IFF_TAP` flags on linux-like system. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is technically an addition since the interface didn't change, but new functionally was added. Please move it to the Added section.
Also change "system" to "systems"
69d0f76
to
42deadf
Compare
Add Flags: `IFF_NO_PI`, `IFF_TUN`, `IFF_TAP`.
bors r+ |
Add Flags:
IFF_NO_PI
,IFF_TUN
,IFF_TAP
.