mirror of
https://github.com/rustdesk/rustdesk.git
synced 2025-01-19 00:13:01 +08:00
open new window not always work, so give it a little time before exit
This commit is contained in:
parent
1f25a8af86
commit
27478946ea
@ -379,6 +379,8 @@ async fn handle(data: Data, stream: &mut Connection) {
|
||||
.spawn()
|
||||
.ok();
|
||||
}
|
||||
// leave above open a little time
|
||||
hbb_common::sleep(0.3).await;
|
||||
}
|
||||
std::process::exit(-1); // to make sure --server luauchagent process can restart because SuccessfulExit used
|
||||
}
|
||||
|
@ -263,6 +263,8 @@ pub fn uninstall_service(show_new_window: bool, sync: bool) -> bool {
|
||||
.arg(&format!("/Applications/{}.app", crate::get_app_name()))
|
||||
.spawn()
|
||||
.ok();
|
||||
// leave open a little time
|
||||
std::thread::sleep(std::time::Duration::from_millis(300));
|
||||
}
|
||||
quit_gui();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user