1
0
mirror of https://github.com/PurpleI2P/i2pd.git synced 2025-01-19 01:09:58 +00:00

check if established peer test session has the same address type

This commit is contained in:
orignal 2024-03-02 18:17:56 -05:00
parent 1292ec67c0
commit 6ba42a0912

View File

@ -858,7 +858,7 @@ namespace transport
{
auto remoteAddr = it->second->GetAddress ();
if (!remoteAddr || !remoteAddr->IsPeerTesting () ||
(v4 && !addr->IsV4 ()) || (!v4 && !addr->IsV6 ())) return false;
(v4 && !remoteAddr->IsV4 ()) || (!v4 && !remoteAddr->IsV6 ())) return false;
auto s = it->second;
if (s->IsEstablished ())
GetService ().post ([s]() { s->SendPeerTest (); });