fix win multi network (#63)

This commit is contained in:
Sijie.Sun
2024-04-28 23:21:58 +08:00
committed by GitHub
parent 577cef131b
commit 6595c2837e
4 changed files with 32 additions and 6 deletions
+9
View File
@@ -273,6 +273,15 @@ impl VirtualNic {
});
}
#[cfg(target_os = "windows")]
{
use std::net::IpAddr;
let c = crate::arch::windows::interface_count()?;
config.name(format!("et{}_{}", self.dev_name, c));
// set a temporary address
config.address(format!("172.0.{}.3", c).parse::<IpAddr>().unwrap());
}
if self.queue_num != 1 {
todo!("queue_num != 1")
}