mirror of
https://github.com/ratspeak/ratdeck.git
synced 2026-10-15 14:09:52 +00:00
TCP scaling, GUI pooling, dev mode, protocol improvements
- TCP: wider drain budgets, TCP_NODELAY, no flush, PSRAM buffers, queue announces until hub ID - GUI: object pool Messages/Contacts screens, partial MessageView status, targeted tab refresh - LVGL throttled to 5fps when dimmed, non-blocking RSSI monitor, bounded I2S writes - LXMF batch drain, BLE frame mutex, LoRa interrupt-driven RX, name cache cap 300 - Developer mode in settings: custom radio params (freq/txp/SF/BW/CR/preamble) behind warning
This commit is contained in:
@@ -173,6 +173,17 @@ void AnnounceManager::received_announce(
|
||||
if (nc == _nameCache.end() || nc->second != name) {
|
||||
_nameCache[destHex] = name;
|
||||
_nameCacheDirty = true;
|
||||
// Cap name cache size: prune entries not in _nodes or saved contacts
|
||||
if ((int)_nameCache.size() > MAX_NAME_CACHE) {
|
||||
for (auto it = _nameCache.begin(); it != _nameCache.end() && (int)_nameCache.size() > MAX_NAME_CACHE; ) {
|
||||
RNS::Bytes h; h.assignHex(it->first.c_str());
|
||||
if (!findNode(h)) {
|
||||
it = _nameCache.erase(it);
|
||||
} else {
|
||||
++it;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user