|
|
@ -428,7 +428,6 @@ namespace tunnel |
|
|
|
{ |
|
|
|
{ |
|
|
|
LogPrint ("Tunnel ", tunnel->GetTunnelID (), " expired"); |
|
|
|
LogPrint ("Tunnel ", tunnel->GetTunnelID (), " expired"); |
|
|
|
{ |
|
|
|
{ |
|
|
|
std::unique_lock<std::mutex> l(m_PoolsMutex); |
|
|
|
|
|
|
|
auto pool = tunnel->GetTunnelPool (); |
|
|
|
auto pool = tunnel->GetTunnelPool (); |
|
|
|
if (pool) |
|
|
|
if (pool) |
|
|
|
pool->TunnelExpired (tunnel); |
|
|
|
pool->TunnelExpired (tunnel); |
|
|
@ -474,7 +473,6 @@ namespace tunnel |
|
|
|
{ |
|
|
|
{ |
|
|
|
LogPrint ("Tunnel ", tunnel->GetTunnelID (), " expired"); |
|
|
|
LogPrint ("Tunnel ", tunnel->GetTunnelID (), " expired"); |
|
|
|
{ |
|
|
|
{ |
|
|
|
std::unique_lock<std::mutex> l(m_PoolsMutex); |
|
|
|
|
|
|
|
auto pool = tunnel->GetTunnelPool (); |
|
|
|
auto pool = tunnel->GetTunnelPool (); |
|
|
|
if (pool) |
|
|
|
if (pool) |
|
|
|
pool->TunnelExpired (tunnel); |
|
|
|
pool->TunnelExpired (tunnel); |
|
|
@ -522,8 +520,8 @@ namespace tunnel |
|
|
|
{ |
|
|
|
{ |
|
|
|
if (ts > it->second->GetCreationTime () + TUNNEL_EXPIRATION_TIMEOUT) |
|
|
|
if (ts > it->second->GetCreationTime () + TUNNEL_EXPIRATION_TIMEOUT) |
|
|
|
{ |
|
|
|
{ |
|
|
|
LogPrint ("Transit tunnel ", it->second->GetTunnelID (), " expired"); |
|
|
|
|
|
|
|
auto tmp = it->second; |
|
|
|
auto tmp = it->second; |
|
|
|
|
|
|
|
LogPrint ("Transit tunnel ", tmp->GetTunnelID (), " expired"); |
|
|
|
{ |
|
|
|
{ |
|
|
|
std::unique_lock<std::mutex> l(m_TransitTunnelsMutex); |
|
|
|
std::unique_lock<std::mutex> l(m_TransitTunnelsMutex); |
|
|
|
it = m_TransitTunnels.erase (it); |
|
|
|
it = m_TransitTunnels.erase (it); |
|
|
|