forked from lx/netapp
fix again
This commit is contained in:
parent
d15378a224
commit
57327f10e2
1 changed files with 9 additions and 2 deletions
|
@ -445,9 +445,16 @@ impl FullMeshPeeringStrategy {
|
||||||
if let Some(host) = known_hosts.list.get_mut(&id) {
|
if let Some(host) = known_hosts.list.get_mut(&id) {
|
||||||
host.state = PeerConnState::Connected;
|
host.state = PeerConnState::Connected;
|
||||||
host.addr = addr;
|
host.addr = addr;
|
||||||
known_hosts.update_hash();
|
} else {
|
||||||
self.update_public_peer_list(&known_hosts);
|
known_hosts.list.insert(id, PeerInfoInternal{
|
||||||
|
state: PeerConnState::Connected,
|
||||||
|
addr,
|
||||||
|
last_seen: None,
|
||||||
|
ping: VecDeque::new(),
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
known_hosts.update_hash();
|
||||||
|
self.update_public_peer_list(&known_hosts);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue