mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-01-22 04:04:16 +00:00
pulish our RouterInfo to 3 floodfills
This commit is contained in:
parent
28042926e7
commit
56836470cf
14
NetDb.cpp
14
NetDb.cpp
@ -550,11 +550,15 @@ namespace data
|
|||||||
void NetDb::Publish ()
|
void NetDb::Publish ()
|
||||||
{
|
{
|
||||||
std::set<IdentHash> excluded; // TODO: fill up later
|
std::set<IdentHash> excluded; // TODO: fill up later
|
||||||
auto floodfill = GetClosestFloodfill (i2p::context.GetRouterInfo ().GetIdentHash (), excluded);
|
for (int i = 0; i < 3; i++)
|
||||||
if (floodfill)
|
{
|
||||||
{
|
auto floodfill = GetClosestFloodfill (i2p::context.GetRouterInfo ().GetIdentHash (), excluded);
|
||||||
LogPrint ("Publishing our RouterInfo to ", floodfill->GetIdentHashAbbreviation ());
|
if (floodfill)
|
||||||
transports.SendMessage (floodfill->GetIdentHash (), CreateDatabaseStoreMsg ());
|
{
|
||||||
|
LogPrint ("Publishing our RouterInfo to ", floodfill->GetIdentHashAbbreviation ());
|
||||||
|
transports.SendMessage (floodfill->GetIdentHash (), CreateDatabaseStoreMsg ());
|
||||||
|
excluded.insert (floodfill->GetIdentHash ());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user