mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-02-07 11:54:16 +00:00
cleanup tags on stop
This commit is contained in:
parent
3480824290
commit
e726d216bb
@ -150,6 +150,7 @@ namespace client
|
|||||||
delete m_Thread;
|
delete m_Thread;
|
||||||
m_Thread = 0;
|
m_Thread = 0;
|
||||||
}
|
}
|
||||||
|
CleanUp (); // GarlicDestination
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -394,6 +394,12 @@ namespace garlic
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void GarlicDestination::CleanUp ()
|
||||||
|
{
|
||||||
|
m_Sessions.clear ();
|
||||||
|
m_DeliveryStatusSessions.clear ();
|
||||||
|
m_Tags.clear ();
|
||||||
|
}
|
||||||
void GarlicDestination::AddSessionKey (const uint8_t * key, const uint8_t * tag)
|
void GarlicDestination::AddSessionKey (const uint8_t * key, const uint8_t * tag)
|
||||||
{
|
{
|
||||||
if (key)
|
if (key)
|
||||||
|
1
Garlic.h
1
Garlic.h
@ -156,6 +156,7 @@ namespace garlic
|
|||||||
GarlicDestination (): m_NumTags (32) {}; // 32 tags by default
|
GarlicDestination (): m_NumTags (32) {}; // 32 tags by default
|
||||||
~GarlicDestination ();
|
~GarlicDestination ();
|
||||||
|
|
||||||
|
void CleanUp ();
|
||||||
void SetNumTags (int numTags) { m_NumTags = numTags; };
|
void SetNumTags (int numTags) { m_NumTags = numTags; };
|
||||||
std::shared_ptr<GarlicRoutingSession> GetRoutingSession (std::shared_ptr<const i2p::data::RoutingDestination> destination, bool attachLeaseSet);
|
std::shared_ptr<GarlicRoutingSession> GetRoutingSession (std::shared_ptr<const i2p::data::RoutingDestination> destination, bool attachLeaseSet);
|
||||||
void CleanupExpiredTags ();
|
void CleanupExpiredTags ();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user