mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
Allow for I2PTunnels without LocalDestination
This commit is contained in:
parent
c5c0d2060c
commit
ccb68088a8
2 changed files with 8 additions and 4 deletions
|
@ -139,6 +139,11 @@ namespace client
|
|||
}
|
||||
}
|
||||
|
||||
I2PTunnel::I2PTunnel (ClientDestination * localDestination) :
|
||||
m_LocalDestination (localDestination ? localDestination :
|
||||
i2p::client::context.CreateNewLocalDestination (false, I2P_TUNNEL_DEFAULT_KEY_TYPE))
|
||||
{
|
||||
}
|
||||
void I2PTunnel::AddConnection (std::shared_ptr<I2PTunnelConnection> conn)
|
||||
{
|
||||
m_Connections.insert (conn);
|
||||
|
@ -155,8 +160,7 @@ namespace client
|
|||
}
|
||||
|
||||
I2PClientTunnel::I2PClientTunnel (const std::string& destination, int port, ClientDestination * localDestination):
|
||||
I2PTunnel (localDestination ? localDestination :
|
||||
i2p::client::context.CreateNewLocalDestination (false, i2p::data::SIGNING_KEY_TYPE_ECDSA_SHA256_P256)),
|
||||
I2PTunnel (localDestination),
|
||||
m_Acceptor (GetService (), boost::asio::ip::tcp::endpoint (boost::asio::ip::tcp::v4(), port)),
|
||||
m_Timer (GetService ()), m_Destination (destination), m_DestinationIdentHash (nullptr),
|
||||
m_RemoteLeaseSet (nullptr)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue