Make format

pull/1151/head
Stephen Shelton 4 years ago
parent 886a981997
commit 9be8050854
No known key found for this signature in database
GPG Key ID: EE4BADACCE8B631C

@ -98,25 +98,26 @@ namespace llarp
// we are relaying this message for e.g. a client
if(relayed)
{
if (relayOrder >= IntroSetStorageRedundancy)
if(relayOrder >= IntroSetStorageRedundancy)
{
llarp::LogWarn("Invalid relayOrder received: ", relayOrder);
replies.emplace_back(new GotIntroMessage({}, txID));
return true;
}
auto closestRCs =
dht.GetRouter()->nodedb()->FindClosestTo(location, IntroSetStorageRedundancy);
auto closestRCs = dht.GetRouter()->nodedb()->FindClosestTo(
location, IntroSetStorageRedundancy);
if (closestRCs.size() <= relayOrder)
if(closestRCs.size() <= relayOrder)
{
llarp::LogWarn("Can't fulfill FindIntro for relayOrder: ", relayOrder);
llarp::LogWarn("Can't fulfill FindIntro for relayOrder: ",
relayOrder);
replies.emplace_back(new GotIntroMessage({}, txID));
return true;
}
const auto& entry = closestRCs[relayOrder];
Key_t peer = Key_t(entry.pubkey);
Key_t peer = Key_t(entry.pubkey);
dht.LookupIntroSetForPath(location, txID, pathID, peer, 0);
}
else

@ -81,8 +81,8 @@ namespace llarp
const llarp::dht::Key_t addr(introset.derivedSigningKey);
// identify closest 4 routers
auto closestRCs =
dht.GetRouter()->nodedb()->FindClosestTo(addr, IntroSetStorageRedundancy);
auto closestRCs = dht.GetRouter()->nodedb()->FindClosestTo(
addr, IntroSetStorageRedundancy);
if(closestRCs.size() != IntroSetStorageRedundancy)
{
llarp::LogWarn("Received PublishIntroMessage but only know ",

@ -452,8 +452,8 @@ namespace llarp
Endpoint::PublishIntroSet(const EncryptedIntroSet& introset,
AbstractRouter* r)
{
const auto paths = GetManyPathsWithUniqueEndpoints(this, llarp::dht::IntroSetRelayRedundancy);
const auto paths = GetManyPathsWithUniqueEndpoints(
this, llarp::dht::IntroSetRelayRedundancy);
if(paths.size() != llarp::dht::IntroSetRelayRedundancy)
{

@ -88,7 +88,7 @@ namespace llarp
void
EndpointUtil::TickRemoteSessions(llarp_time_t now, Sessions& remoteSessions,
Sessions& deadSessions, ConvoMap & sessions)
Sessions& deadSessions, ConvoMap& sessions)
{
auto itr = remoteSessions.begin();
while(itr != remoteSessions.end())

@ -23,7 +23,7 @@ namespace llarp
static void
TickRemoteSessions(llarp_time_t now, Sessions& remoteSessions,
Sessions& deadSessions, ConvoMap & sessions);
Sessions& deadSessions, ConvoMap& sessions);
static void
ExpireConvoSessions(llarp_time_t now, ConvoMap& sessions);

Loading…
Cancel
Save