save updated local RouterInfo in separate thread

This commit is contained in:
orignal 2025-01-28 20:49:36 -05:00
parent 5d7a062f1b
commit daeb177579
2 changed files with 19 additions and 2 deletions

View file

@ -13,6 +13,7 @@
#include <string>
#include <memory>
#include <random>
#include <future>
#include <unordered_set>
#include <boost/asio.hpp>
#include "Identity.h"
@ -266,6 +267,7 @@ namespace garlic
bool m_IsHiddenMode; // not publish
mutable std::mutex m_RouterInfoMutex;
std::mt19937 m_Rng;
std::future<void> m_SavingRouterInfo;
};
extern RouterContext context;