完善配置
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
use std::io;
|
||||
use std::net::{Ipv4Addr, SocketAddr, SocketAddrV4, UdpSocket};
|
||||
|
||||
use std::sync::Arc;
|
||||
|
||||
use console::style;
|
||||
@@ -54,6 +53,7 @@ impl CommandServer {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fn command(cmd: &str, switch: &Switch) -> io::Result<String> {
|
||||
let mut out_str = String::new();
|
||||
match cmd {
|
||||
@@ -129,6 +129,13 @@ fn command(cmd: &str, switch: &Switch) -> io::Result<String> {
|
||||
let str = format!("Delay of relay server :{}ms\n", style(server_rt).green());
|
||||
out_str.push_str(&str);
|
||||
}
|
||||
if let Some(nat_info) = switch.nat_info() {
|
||||
let str = format!(
|
||||
"NAT type :{}",
|
||||
style(format!("{:?}", nat_info.nat_type)).green()
|
||||
);
|
||||
out_str.push_str(&str);
|
||||
}
|
||||
}
|
||||
"help" | "h" => {
|
||||
let str = format!("Options: \n");
|
||||
|
||||
Reference in New Issue
Block a user