implement i2cp session reconfigure

This commit is contained in:
Jeff Becker 2018-01-02 11:34:58 -05:00
parent 7b00d828b2
commit 938d5d901a
No known key found for this signature in database
GPG key ID: F357B3B42F6F9B05
5 changed files with 114 additions and 2 deletions

View file

@ -69,6 +69,18 @@ namespace tunnel
m_Tests.clear ();
}
bool TunnelPool::Reconfigure(int inHops, int outHops, int inQuant, int outQuant) {
if( inHops >= 0 && outHops >= 0 && inQuant > 0 && outQuant > 0)
{
m_NumInboundHops = inHops;
m_NumOutboundHops = outHops;
m_NumInboundTunnels = inQuant;
m_NumOutboundTunnels = outQuant;
return true;
}
return false;
}
void TunnelPool::TunnelCreated (std::shared_ptr<InboundTunnel> createdTunnel)
{
if (!m_IsActive) return;