|
|
@ -231,7 +231,6 @@ namespace transport |
|
|
|
|
|
|
|
|
|
|
|
void Transports::SendMessages (const i2p::data::IdentHash& ident, const std::vector<std::shared_ptr<i2p::I2NPMessage> >& msgs) |
|
|
|
void Transports::SendMessages (const i2p::data::IdentHash& ident, const std::vector<std::shared_ptr<i2p::I2NPMessage> >& msgs) |
|
|
|
{ |
|
|
|
{ |
|
|
|
|
|
|
|
|
|
|
|
EmitEvent({{"type" , "transport.sendmsg"}, {"ident", ident.ToBase64()}, {"number", std::to_string(msgs.size())}}); |
|
|
|
EmitEvent({{"type" , "transport.sendmsg"}, {"ident", ident.ToBase64()}, {"number", std::to_string(msgs.size())}}); |
|
|
|
m_Service.post (std::bind (&Transports::PostMessages, this, ident, msgs)); |
|
|
|
m_Service.post (std::bind (&Transports::PostMessages, this, ident, msgs)); |
|
|
|
} |
|
|
|
} |
|
|
@ -510,7 +509,6 @@ namespace transport |
|
|
|
bool nat; i2p::config::GetOption("nat", nat); |
|
|
|
bool nat; i2p::config::GetOption("nat", nat); |
|
|
|
if (nat) |
|
|
|
if (nat) |
|
|
|
i2p::context.SetStatus (eRouterStatusTesting); |
|
|
|
i2p::context.SetStatus (eRouterStatusTesting); |
|
|
|
|
|
|
|
|
|
|
|
for (int i = 0; i < 5; i++) |
|
|
|
for (int i = 0; i < 5; i++) |
|
|
|
{ |
|
|
|
{ |
|
|
|
auto router = i2p::data::netdb.GetRandomPeerTestRouter (); |
|
|
|
auto router = i2p::data::netdb.GetRandomPeerTestRouter (); |
|
|
@ -573,7 +571,6 @@ namespace transport |
|
|
|
if (it != m_Peers.end ()) |
|
|
|
if (it != m_Peers.end ()) |
|
|
|
{ |
|
|
|
{ |
|
|
|
EmitEvent({{"type" , "transport.connected"}, {"ident", ident.ToBase64()}, {"inbound", "false"}}); |
|
|
|
EmitEvent({{"type" , "transport.connected"}, {"ident", ident.ToBase64()}, {"inbound", "false"}}); |
|
|
|
|
|
|
|
|
|
|
|
bool sendDatabaseStore = true; |
|
|
|
bool sendDatabaseStore = true; |
|
|
|
if (it->second.delayedMessages.size () > 0) |
|
|
|
if (it->second.delayedMessages.size () > 0) |
|
|
|
{ |
|
|
|
{ |
|
|
|