mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
request RouterInfo if outdated
This commit is contained in:
parent
8d3fcff5c5
commit
1862896532
2 changed files with 5 additions and 3 deletions
|
@ -442,9 +442,11 @@ namespace data
|
|||
|
||||
if (dest->IsExploratory ())
|
||||
{
|
||||
if (!FindRouter (router)) // router with ident not found
|
||||
auto r = FindRouter (router);
|
||||
if (!r || i2p::util::GetMillisecondsSinceEpoch () > r->GetTimestamp () + 3600*1000LL)
|
||||
{
|
||||
LogPrint ("Found new router. Requesting RouterInfo ...");
|
||||
// router with ident not found or too old (1 hour)
|
||||
LogPrint ("Found new/outdated router. Requesting RouterInfo ...");
|
||||
if (outbound && inbound)
|
||||
{
|
||||
RequestedDestination * d1 = CreateRequestedDestination (router, false, false);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue