mirror of
https://github.com/PurpleI2P/i2pd
synced 2024-11-10 16:10:33 +03:00
check transport compatibility with peer before connecting
This commit is contained in:
parent
0e5dc15005
commit
33b82b5669
@ -351,6 +351,7 @@ namespace transport
|
||||
try
|
||||
{
|
||||
auto r = netdb.FindRouter (ident);
|
||||
if (!r || !r->IsCompatible (i2p::context.GetRouterInfo ())) return;
|
||||
{
|
||||
std::unique_lock<std::mutex> l(m_PeersMutex);
|
||||
it = m_Peers.insert (std::pair<i2p::data::IdentHash, Peer>(ident, { 0, r, {},
|
||||
|
Loading…
Reference in New Issue
Block a user