mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-01-22 21:37:17 +01:00
set status OK after both peer test msg 4 and 5
This commit is contained in:
parent
aa21748e9a
commit
f7e9e6a1c4
|
@ -1687,6 +1687,7 @@ namespace transport
|
|||
if (it->second.first->m_State == eSSU2SessionStatePeerTestReceived)
|
||||
{
|
||||
// msg 5 already received. send msg 6
|
||||
SetRouterStatus (eRouterStatusOK);
|
||||
it->second.first->m_State = eSSU2SessionStatePeerTest;
|
||||
it->second.first->SendPeerTest (6, buf + offset, len - offset, addr->i);
|
||||
}
|
||||
|
@ -1725,11 +1726,13 @@ namespace transport
|
|||
if (htobe64 (((uint64_t)nonce << 32) | nonce) == m_SourceConnID)
|
||||
{
|
||||
if (m_Address)
|
||||
{
|
||||
SetRouterStatus (eRouterStatusOK);
|
||||
SendPeerTest (6, buf + offset, len - offset, m_Address->i);
|
||||
}
|
||||
else
|
||||
// we received msg 5 before msg 4
|
||||
m_State = eSSU2SessionStatePeerTestReceived;
|
||||
SetRouterStatus (eRouterStatusOK);
|
||||
}
|
||||
else
|
||||
LogPrint (eLogWarning, "SSU2: Peer test 5 nonce mismatch ", nonce, " connID=", m_SourceConnID);
|
||||
|
|
Loading…
Reference in a new issue