mirror of
https://github.com/PurpleI2P/i2pd
synced 2024-11-10 08:00:38 +03:00
don't try to connect to unreachable router from unreachable router
This commit is contained in:
parent
8f3414bcb2
commit
7ec2318bba
4
SSU.cpp
4
SSU.cpp
@ -1030,7 +1030,7 @@ namespace ssu
|
|||||||
{
|
{
|
||||||
// connect through introducer
|
// connect through introducer
|
||||||
int numIntroducers = address->introducers.size ();
|
int numIntroducers = address->introducers.size ();
|
||||||
if (numIntroducers > 0)
|
if (numIntroducers > 0 && !i2p::context.GetRouterInfo ().UsesIntroducer ())
|
||||||
{
|
{
|
||||||
SSUSession * introducerSession = nullptr;
|
SSUSession * introducerSession = nullptr;
|
||||||
const i2p::data::RouterInfo::Introducer * introducer = nullptr;
|
const i2p::data::RouterInfo::Introducer * introducer = nullptr;
|
||||||
@ -1064,7 +1064,7 @@ namespace ssu
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
LogPrint ("Router is unreachable, but no introducers presented. Ignored");
|
LogPrint ("Can't connect to unreachable router. ", numIntroducers ? "We are unreachable" : "No introducers presented");
|
||||||
m_Sessions.erase (remoteEndpoint);
|
m_Sessions.erase (remoteEndpoint);
|
||||||
delete session;
|
delete session;
|
||||||
session = nullptr;
|
session = nullptr;
|
||||||
|
Loading…
Reference in New Issue
Block a user