mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2026-10-04 03:49:34 +00:00
remove empty buckets after load DHT nodes
This commit is contained in:
@@ -498,6 +498,7 @@ namespace torrents
|
||||
}
|
||||
}
|
||||
}
|
||||
m_RoutingTable->RemoveEmptyBuckets ();
|
||||
if (numLoaded > 0)
|
||||
LogPrint (eLogInfo, "TorrentsDHT: ", numLoaded, " DHT nodes loaded");
|
||||
}
|
||||
|
||||
@@ -123,11 +123,11 @@ namespace torrents
|
||||
std::list<std::pair<NodeID, NodeID> > GetExploratoryTargets (std::mt19937& rng) const; // (target, node to send find_node to)
|
||||
NodeID FindClosestNodeInBucket (const NodeID& target) const;
|
||||
std::list<NodeID> DeleteExpiredNodes (uint64_t ts);
|
||||
void RemoveEmptyBuckets ();
|
||||
|
||||
private:
|
||||
|
||||
Bucket * FindBucket (const Torrent::InfoHash& id) const;
|
||||
void RemoveEmptyBuckets ();
|
||||
|
||||
private:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user