WIP: Fixes for link validation and announce retries

Fix for link validation failure when poackets contain new MTU in payload
from RNS 1.0 (courtesy of @jlpoolen).
Optimization of announce re-broadcasts from RNS 1.0.
This commit is contained in:
Chad Attermann committed 2026-02-15 09:59:25 -07:00
1 parent 3cc7c2a55d
commit 3c4978f294
8 files changed
+68 -10

No files matched your search

+7 -1
View File
@@ -334,7 +334,13 @@ using namespace RNS::Utilities;
// auto& announce_entry = pair.second;
//TRACE("[0] announce entry data size: " + std::to_string(announce_entry._packet.data().size()));
//p announce_entry = Transport.announce_table[destination_hash]
if (announce_entry._retries > Type::Transport::PATHFINDER_R) {
if (announce_entry._retries > 0 && announce_entry._retries >= Type::Transport::LOCAL_REBROADCASTS_MAX) {
TRACE("Completed announce processing for " + destination_hash.toHex() + ", local rebroadcast limit reached");
// CBA OK to modify collection here since we're immediately exiting iteration
_announce_table.erase(destination_hash);
break;
}
else if (announce_entry._retries > Type::Transport::PATHFINDER_R) {
TRACE("Completed announce processing for " + destination_hash.toHex() + ", retry limit reached");
// CBA OK to modify collection here since we're immediately exiting iteration
_announce_table.erase(destination_hash);