allow listener retry listen (#554)

This commit is contained in:
Sijie.Sun
2025-01-09 00:01:41 +08:00
committed by GitHub
parent d2ec60e108
commit 306817ae9a
3 changed files with 157 additions and 73 deletions

View File

@@ -230,7 +230,10 @@ impl GlobalCtx {
}
pub fn add_running_listener(&self, url: url::Url) {
self.running_listeners.lock().unwrap().push(url);
let mut l = self.running_listeners.lock().unwrap();
if !l.contains(&url) {
l.push(url);
}
}
pub fn get_vpn_portal_cidr(&self) -> Option<cidr::Ipv4Cidr> {