fix MAX_ANON_CONTACTS

This commit is contained in:
liquidraver
2026-06-07 12:51:31 +02:00
parent 01fd56a573
commit 37edf303a2
+2 -1
View File
@@ -84,7 +84,8 @@ void BaseChatMesh::bootstrapRTCfromContacts()
ContactInfo *BaseChatMesh::allocateContactSlot(bool transient_only)
{
if (num_contacts < MAX_CONTACTS) {
int max_slots = transient_only ? (MAX_CONTACTS + MAX_ANON_CONTACTS) : MAX_CONTACTS;
if (num_contacts < max_slots) {
return &contacts[num_contacts++];
} else if (transient_only || shouldOverwriteWhenFull()) {
int oldest_idx = -1;