Skip to content

Commit

Permalink
Zenoh only considers UP and RUNNING network interfaces (#573)
Browse files Browse the repository at this point in the history
  • Loading branch information
OlivierHecart committed Jan 3, 2024
1 parent 42b8064 commit ee85696
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions commons/zenoh-util/src/std_only/net/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,7 @@ pub fn get_local_addresses() -> ZResult<Vec<IpAddr>> {
{
Ok(pnet_datalink::interfaces()
.into_iter()
.filter(|iface| iface.is_up() && iface.is_running())
.flat_map(|iface| iface.ips)
.map(|ipnet| ipnet.ip())
.collect())
Expand Down

0 comments on commit ee85696

Please sign in to comment.