Browse Source

reduce minimal # of routers to 50

pull/118/head
orignal 10 years ago
parent
commit
bb5e520a79
  1. 6
      NetDb.cpp

6
NetDb.cpp

@ -78,14 +78,14 @@ namespace data
void NetDb::Start () void NetDb::Start ()
{ {
Load (m_NetDbPath); Load (m_NetDbPath);
if (m_RouterInfos.size () < 100) // reseed if # of router less than 100 if (m_RouterInfos.size () < 50) // reseed if # of router less than 50
{ {
Reseeder reseeder; Reseeder reseeder;
reseeder.LoadCertificates (); // we need certificates for SU3 verification reseeder.LoadCertificates (); // we need certificates for SU3 verification
// try SU3 first // try SU3 first
int reseedRetries = 0; int reseedRetries = 0;
while (m_RouterInfos.size () < 100 && reseedRetries < 10) while (m_RouterInfos.size () < 50 && reseedRetries < 10)
{ {
reseeder.ReseedNowSU3(); reseeder.ReseedNowSU3();
reseedRetries++; reseedRetries++;
@ -93,7 +93,7 @@ namespace data
// if still not enough download .dat files // if still not enough download .dat files
reseedRetries = 0; reseedRetries = 0;
while (m_RouterInfos.size () < 100 && reseedRetries < 10) while (m_RouterInfos.size () < 50 && reseedRetries < 10)
{ {
reseeder.reseedNow(); reseeder.reseedNow();
reseedRetries++; reseedRetries++;

Loading…
Cancel
Save