Faster roaming path recovery for multiple interface non-transport instances

This commit is contained in:
Mark Qvist 2022-12-22 20:17:09 +01:00
parent c34c268a6a
commit 8402541c73

View File

@ -401,6 +401,11 @@ class Transport:
if lr_taken_hops == 0 and time.time() - last_path_request > Transport.PATH_REQUEST_MI: if lr_taken_hops == 0 and time.time() - last_path_request > Transport.PATH_REQUEST_MI:
RNS.log("Trying to rediscover path for "+RNS.prettyhexrep(link_entry[6])+" since an attempted link was never established", RNS.LOG_DEBUG) RNS.log("Trying to rediscover path for "+RNS.prettyhexrep(link_entry[6])+" since an attempted link was never established", RNS.LOG_DEBUG)
path_requests.append(link_entry[6]) path_requests.append(link_entry[6])
if not RNS.Reticulum.transport_enabled():
# Drop current path if we are not a transport instance, to
# allow using higher-hop count paths or reused announces
# from newly adjacent transport instances.
Transport.expire_path(link_entry[6])
# Cull the path table # Cull the path table
stale_paths = [] stale_paths = []
@ -562,9 +567,6 @@ class Transport:
Transport.jobs_locked = True Transport.jobs_locked = True
# TODO: This updateHash call might be redundant
# packet.update_hash()
sent = False sent = False
outbound_time = time.time() outbound_time = time.time()