Browse Source

start initial peer test if SSU2 only

pull/1776/head
orignal 2 years ago
parent
commit
8feac310af
  1. 6
      libi2pd/Transports.cpp

6
libi2pd/Transports.cpp

@ -285,8 +285,8 @@ namespace transport
delete m_SSUServer; delete m_SSUServer;
m_SSUServer = nullptr; m_SSUServer = nullptr;
} }
if (m_SSUServer) DetectExternalIP ();
} }
if (m_SSUServer || m_SSU2Server) DetectExternalIP ();
m_PeerCleanupTimer->expires_from_now (boost::posix_time::seconds(5*SESSION_CREATION_TIMEOUT)); m_PeerCleanupTimer->expires_from_now (boost::posix_time::seconds(5*SESSION_CREATION_TIMEOUT));
m_PeerCleanupTimer->async_wait (std::bind (&Transports::HandlePeerCleanupTimer, this, std::placeholders::_1)); m_PeerCleanupTimer->async_wait (std::bind (&Transports::HandlePeerCleanupTimer, this, std::placeholders::_1));
@ -622,10 +622,10 @@ namespace transport
i2p::context.SetStatus (eRouterStatusOK); i2p::context.SetStatus (eRouterStatusOK);
return; return;
} }
if (m_SSUServer) if (m_SSUServer || m_SSU2Server)
PeerTest (); PeerTest ();
else else
LogPrint (eLogError, "Transports: Can't detect external IP. SSU is not available"); LogPrint (eLogWarning, "Transports: Can't detect external IP. SSU or SSU2 is not available");
} }
void Transports::PeerTest (bool ipv4, bool ipv6) void Transports::PeerTest (bool ipv4, bool ipv6)

Loading…
Cancel
Save