Skip to content

Commit

Permalink
Only activate AddressFamily::Bridge on Linux
Browse files Browse the repository at this point in the history
Not supported on FreeBSD.

Signed-off-by: Yann Dirson <[email protected]>
  • Loading branch information
ydirson committed Jan 10, 2024
1 parent 0fc0d54 commit 9a16d8c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/neighbour/add.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ impl NeighbourAddRequest {
}
}

#[cfg(any(linux, android))]
pub(crate) fn new_bridge(handle: Handle, index: u32, lla: &[u8]) -> Self {
let mut message = NeighbourMessage::default();

Expand Down
1 change: 1 addition & 0 deletions src/neighbour/handle.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ impl NeighbourHandle {
NeighbourAddRequest::new(self.0.clone(), index, destination)
}

#[cfg(any(linux, android))]
/// Add a new fdb entry (equivalent to `bridge fdb add`)
pub fn add_bridge(&self, index: u32, lla: &[u8]) -> NeighbourAddRequest {
NeighbourAddRequest::new_bridge(self.0.clone(), index, lla)
Expand Down

0 comments on commit 9a16d8c

Please sign in to comment.