Skip to content

Commit

Permalink
[skip ci] Implement get_interface_names for serial link
Browse files Browse the repository at this point in the history
  • Loading branch information
sashacmc committed Feb 28, 2024
1 parent 3324989 commit b322776
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion io/zenoh-links/zenoh-link-serial/src/unicast.rs
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,16 @@ impl LinkUnicastTrait for LinkUnicastSerial {

#[inline(always)]
fn get_interface_names(&self) -> Vec<String> {
vec![String::from("serial")]
match z_serial::get_available_port_names() {
Ok(interfaces) => {
log::debug!("get_interface_names for serial: {:?}", interfaces);
interfaces
}
Err(e) => {
log::debug!("get_interface_names for serial failed: {:?}", e);
vec![]
}
}
}

#[inline(always)]
Expand Down

0 comments on commit b322776

Please sign in to comment.