mirror of
https://github.com/markqvist/Reticulum.git
synced 2024-11-26 07:20:18 +00:00
Differentiate exception between link establishment callback, and internal RTT packet handling
This commit is contained in:
parent
bbfdd37935
commit
777fea9cea
@ -379,8 +379,11 @@ class Link:
|
|||||||
if self.rtt != None and self.establishment_cost != None and self.rtt > 0 and self.establishment_cost > 0:
|
if self.rtt != None and self.establishment_cost != None and self.rtt > 0 and self.establishment_cost > 0:
|
||||||
self.establishment_rate = self.establishment_cost/self.rtt
|
self.establishment_rate = self.establishment_cost/self.rtt
|
||||||
|
|
||||||
if self.owner.callbacks.link_established != None:
|
try:
|
||||||
self.owner.callbacks.link_established(self)
|
if self.owner.callbacks.link_established != None:
|
||||||
|
self.owner.callbacks.link_established(self)
|
||||||
|
except Exception as e:
|
||||||
|
RNS.log("Error occurred in external link establishment callback. The contained exception was: "+str(e), RNS.LOG_ERROR)
|
||||||
|
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
RNS.log("Error occurred while processing RTT packet, tearing down link. The contained exception was: "+str(e), RNS.LOG_ERROR)
|
RNS.log("Error occurred while processing RTT packet, tearing down link. The contained exception was: "+str(e), RNS.LOG_ERROR)
|
||||||
|
Loading…
Reference in New Issue
Block a user