diff --git a/src/seeder/db.h b/src/seeder/db.h --- a/src/seeder/db.h +++ b/src/seeder/db.h @@ -112,12 +112,12 @@ ret.uptime[3] = stat1W.reliability; ret.uptime[4] = stat1M.reliability; ret.lastSuccess = ourLastSuccess; - ret.fGood = IsGood(); + ret.fGood = IsReliable(); ret.services = services; return ret; } - bool IsGood() const { + bool IsReliable() const { if (ip.GetPort() != GetDefaultPort()) { return false; } @@ -158,7 +158,7 @@ } int64_t GetBanTime() const { - if (IsGood()) { + if (IsReliable()) { return 0; } if (clientVersion && clientVersion < 31900) { @@ -180,7 +180,7 @@ } int64_t GetIgnoreTime() const { - if (IsGood()) { + if (IsReliable()) { return 0; } if (stat1M.reliability - stat1M.weight + 1.0 < 0.20 && @@ -399,7 +399,7 @@ db->ipToId[info.ip] = id; if (info.ourLastTry) { db->ourId.push_back(id); - if (info.IsGood()) { + if (info.IsReliable()) { db->goodId.insert(id); } } else { diff --git a/src/seeder/db.cpp b/src/seeder/db.cpp --- a/src/seeder/db.cpp +++ b/src/seeder/db.cpp @@ -97,7 +97,7 @@ info.clientSubVersion = clientSV; info.blocks = blocks; info.Update(true); - if (info.IsGood() && goodId.count(id) == 0) { + if (info.IsReliable() && goodId.count(id) == 0) { goodId.insert(id); // tfm::format(std::cout, "%s: good; %i good nodes now\n", // ToString(addr).c_str(), (int)goodId.size()); @@ -130,7 +130,7 @@ goodId.erase(id); idToInfo.erase(id); } else { - if (/*!info.IsGood() && */ goodId.count(id) == 1) { + if (/*!info.IsReliable() && */ goodId.count(id) == 1) { goodId.erase(id); // tfm::format(std::cout, "%s: not good; %i good nodes left\n", // ToString(addr).c_str(), (int)goodId.size());