mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-02-02 11:04:00 +01:00
resseed if too few floodfills
This commit is contained in:
parent
2f88a75325
commit
20652f7995
|
@ -55,8 +55,10 @@ namespace data
|
||||||
Load ();
|
Load ();
|
||||||
|
|
||||||
uint16_t threshold; i2p::config::GetOption("reseed.threshold", threshold);
|
uint16_t threshold; i2p::config::GetOption("reseed.threshold", threshold);
|
||||||
if (m_RouterInfos.size () < threshold) // reseed if # of router less than threshold
|
if (m_RouterInfos.size () < threshold || m_Floodfills.size () < NETDB_MIN_FLOODFILLS) // reseed if # of router less than threshold or too few floodfiils
|
||||||
|
{
|
||||||
Reseed ();
|
Reseed ();
|
||||||
|
}
|
||||||
else if (!GetRandomRouter (i2p::context.GetSharedRouterInfo (), false))
|
else if (!GetRandomRouter (i2p::context.GetSharedRouterInfo (), false))
|
||||||
Reseed (); // we don't have a router we can connect to. Trying to reseed
|
Reseed (); // we don't have a router we can connect to. Trying to reseed
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue