lan_discovery_WOL: lan discovery test done

Signed-off-by: fufesou <shuanglongchen@yeah.net>
This commit is contained in:
fufesou
2022-07-14 03:35:00 +08:00
parent 8fd4830710
commit eda0855506
2 changed files with 7 additions and 5 deletions

View File

@@ -64,9 +64,11 @@ impl RendezvousMediator {
direct_server(server_cloned).await;
});
#[cfg(not(any(target_os = "android", target_os = "ios")))]
std::thread::spawn(move || {
allow_err!(lan_discovery());
});
if crate::platform::is_installed() {
std::thread::spawn(move || {
allow_err!(lan_discovery());
});
}
loop {
Config::reset_online();
if Config::get_option("stop-service").is_empty() {