mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
reuse DH keys pairs from failed NTCP sessions
This commit is contained in:
parent
06f9e68169
commit
7019b6d68f
3 changed files with 23 additions and 1 deletions
|
@ -26,6 +26,7 @@ namespace i2p
|
|||
void Start ();
|
||||
void Stop ();
|
||||
i2p::data::DHKeysPair * Acquire ();
|
||||
void Return (i2p::data::DHKeysPair * pair);
|
||||
|
||||
private:
|
||||
|
||||
|
@ -34,7 +35,7 @@ namespace i2p
|
|||
|
||||
private:
|
||||
|
||||
int m_QueueSize;
|
||||
const int m_QueueSize;
|
||||
std::queue<i2p::data::DHKeysPair *> m_Queue;
|
||||
|
||||
bool m_IsRunning;
|
||||
|
@ -55,6 +56,7 @@ namespace i2p
|
|||
|
||||
boost::asio::io_service& GetService () { return m_Service; };
|
||||
i2p::data::DHKeysPair * GetNextDHKeysPair ();
|
||||
void ReuseDHKeysPair (i2p::data::DHKeysPair * pair);
|
||||
|
||||
void AddNTCPSession (i2p::ntcp::NTCPSession * session);
|
||||
void RemoveNTCPSession (i2p::ntcp::NTCPSession * session);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue