mirror of
https://github.com/markqvist/Reticulum.git
synced 2026-11-19 14:36:34 -05:00
Cleanup
This commit is contained in:
parent
1fee7af7f2
commit
baccc6d8a2
1 changed files with 6 additions and 3 deletions
|
|
@ -272,8 +272,8 @@ class Destination:
|
|||
stamp, stamp_value = generate_stamp(self.stamp_material(), stamp_cost=self.target_value,
|
||||
expand_rounds=0, size=RNS.Identity.STAMPLENGTH)
|
||||
if stamp == None:
|
||||
RNS.log(f"Could not generate destination stamp for {RNS.prettyhexrep(self.hash)}, announce emission cancelled", RNS.LOG_WARNING)
|
||||
return
|
||||
RNS.log(f"Destination stamp generation for {RNS.prettyhexrep(self.hash)} failed or was aborted", RNS.LOG_DEBUG)
|
||||
return False
|
||||
|
||||
self.stamp = stamp
|
||||
self.stamp_value = stamp_value
|
||||
|
|
@ -346,7 +346,10 @@ class Destination:
|
|||
app_data = returned_app_data
|
||||
|
||||
if RNS.Transport.STAMP_DESTINATIONS:
|
||||
self._await_stamp()
|
||||
if not self._await_stamp():
|
||||
RNS.log(f"Could not generate destination stamp for {RNS.prettyhexrep(self.hash)}, announce emission cancelled", RNS.LOG_WARNING)
|
||||
return None
|
||||
|
||||
cost_bytes = cost_to_bytes(self.get_link_cost())
|
||||
ext_payload = bytes([RNS.Identity.EXTPAYLOADMARKER, self.get_ext_flags()])+self.stamp+bytes([cost_bytes[1], cost_bytes[0]])
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue