mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
connect to introducer if not any yet
This commit is contained in:
parent
b95b49bd19
commit
ccf689ffd5
3 changed files with 17 additions and 0 deletions
|
@ -894,6 +894,15 @@ namespace data
|
|||
});
|
||||
}
|
||||
|
||||
std::shared_ptr<const RouterInfo> NetDb::GetRandomIntroducer () const
|
||||
{
|
||||
return GetRandomRouter (
|
||||
[](std::shared_ptr<const RouterInfo> router)->bool
|
||||
{
|
||||
return !router->IsHidden () && router->IsIntroducer ();
|
||||
});
|
||||
}
|
||||
|
||||
std::shared_ptr<const RouterInfo> NetDb::GetHighBandwidthRandomRouter (std::shared_ptr<const RouterInfo> compatibleWith) const
|
||||
{
|
||||
return GetRandomRouter (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue