aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorrustdesk <[email protected]>2023-06-08 20:02:30 +0800
committerrustdesk <[email protected]>2023-06-08 20:02:30 +0800
commit411502cd0bed81101111226b18d154aba10170e9 (patch)
treefdd2a6f70f3baa7395238b8bdb75b02a734264f2 /src
parent243fb1fb060c6e8b15e135db8cf9726e4ce87c0f (diff)
downloadrustdesk-server-411502cd0bed81101111226b18d154aba10170e9.tar.gz
rustdesk-server-411502cd0bed81101111226b18d154aba10170e9.zip
https://github.com/rustdesk/rustdesk-server/issues/260
Diffstat (limited to 'src')
-rw-r--r--src/rendezvous_server.rs13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/rendezvous_server.rs b/src/rendezvous_server.rs
index 5db44e6..a5ba9bb 100644
--- a/src/rendezvous_server.rs
+++ b/src/rendezvous_server.rs
@@ -167,8 +167,17 @@ impl RendezvousServer {
};
tokio::spawn(async move {
if let Err(err) = test_hbbs(test_addr).await {
- log::error!("Failed to run hbbs test with {test_addr}: {err}");
- std::process::exit(1);
+ if test_addr.is_ipv6() && test_addr.ip().is_unspecified() {
+ let mut test_addr = test_addr;
+ test_addr.set_ip(IpAddr::V4(Ipv4Addr::UNSPECIFIED));
+ if let Err(err) = test_hbbs(test_addr).await {
+ log::error!("Failed to run hbbs test with {test_addr}: {err}");
+ std::process::exit(1);
+ }
+ } else {
+ log::error!("Failed to run hbbs test with {test_addr}: {err}");
+ std::process::exit(1);
+ }
}
});
};