mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-01-24 22:44:15 +00:00
fixed typo
This commit is contained in:
parent
5f39f65540
commit
bb6212ccc1
@ -31,7 +31,7 @@ namespace data
|
|||||||
std::shared_ptr<I2NPMessage> RequestedDestination::CreateRequestMessage (std::shared_ptr<const RouterInfo> router,
|
std::shared_ptr<I2NPMessage> RequestedDestination::CreateRequestMessage (std::shared_ptr<const RouterInfo> router,
|
||||||
std::shared_ptr<const i2p::tunnel::InboundTunnel> replyTunnel)
|
std::shared_ptr<const i2p::tunnel::InboundTunnel> replyTunnel)
|
||||||
{
|
{
|
||||||
std::lock_guard<std::mutex> l (m_ExcludedPeerstMutex);
|
std::lock_guard<std::mutex> l (m_ExcludedPeersMutex);
|
||||||
std::shared_ptr<I2NPMessage> msg;
|
std::shared_ptr<I2NPMessage> msg;
|
||||||
if(replyTunnel)
|
if(replyTunnel)
|
||||||
msg = i2p::CreateRouterInfoDatabaseLookupMsg (m_Destination,
|
msg = i2p::CreateRouterInfoDatabaseLookupMsg (m_Destination,
|
||||||
@ -47,6 +47,7 @@ namespace data
|
|||||||
|
|
||||||
std::shared_ptr<I2NPMessage> RequestedDestination::CreateRequestMessage (const IdentHash& floodfill)
|
std::shared_ptr<I2NPMessage> RequestedDestination::CreateRequestMessage (const IdentHash& floodfill)
|
||||||
{
|
{
|
||||||
|
std::lock_guard<std::mutex> l (m_ExcludedPeersMutex);
|
||||||
auto msg = i2p::CreateRouterInfoDatabaseLookupMsg (m_Destination,
|
auto msg = i2p::CreateRouterInfoDatabaseLookupMsg (m_Destination,
|
||||||
i2p::context.GetRouterInfo ().GetIdentHash () , 0, false, &m_ExcludedPeers);
|
i2p::context.GetRouterInfo ().GetIdentHash () , 0, false, &m_ExcludedPeers);
|
||||||
m_ExcludedPeers.insert (floodfill);
|
m_ExcludedPeers.insert (floodfill);
|
||||||
@ -56,13 +57,13 @@ namespace data
|
|||||||
|
|
||||||
bool RequestedDestination::IsExcluded (const IdentHash& ident) const
|
bool RequestedDestination::IsExcluded (const IdentHash& ident) const
|
||||||
{
|
{
|
||||||
std::lock_guard<std::mutex> l (m_ExcludedPeerstMutex);
|
std::lock_guard<std::mutex> l (m_ExcludedPeersMutex);
|
||||||
return m_ExcludedPeers.count (ident);
|
return m_ExcludedPeers.count (ident);
|
||||||
}
|
}
|
||||||
|
|
||||||
void RequestedDestination::ClearExcludedPeers ()
|
void RequestedDestination::ClearExcludedPeers ()
|
||||||
{
|
{
|
||||||
std::lock_guard<std::mutex> l (m_ExcludedPeerstMutex);
|
std::lock_guard<std::mutex> l (m_ExcludedPeersMutex);
|
||||||
m_ExcludedPeers.clear ();
|
m_ExcludedPeers.clear ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -57,7 +57,7 @@ namespace data
|
|||||||
|
|
||||||
IdentHash m_Destination;
|
IdentHash m_Destination;
|
||||||
bool m_IsExploratory, m_IsDirect, m_IsActive;
|
bool m_IsExploratory, m_IsDirect, m_IsActive;
|
||||||
mutable std::mutex m_ExcludedPeerstMutex;
|
mutable std::mutex m_ExcludedPeersMutex;
|
||||||
std::set<IdentHash> m_ExcludedPeers;
|
std::set<IdentHash> m_ExcludedPeers;
|
||||||
uint64_t m_CreationTime, m_LastRequestTime; // in seconds
|
uint64_t m_CreationTime, m_LastRequestTime; // in seconds
|
||||||
RequestComplete m_RequestComplete;
|
RequestComplete m_RequestComplete;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user