|
|
|
@ -605,10 +605,12 @@ namespace llarp
|
|
|
|
|
Path::HandlePathLatencyMessage(
|
|
|
|
|
const llarp::routing::PathLatencyMessage* msg, llarp_router* r)
|
|
|
|
|
{
|
|
|
|
|
auto now = llarp_time_now_ms();
|
|
|
|
|
m_LastRecvMessage = now;
|
|
|
|
|
// TODO: reanimate dead paths if they get this message
|
|
|
|
|
if(msg->L == m_LastLatencyTestID && _status == ePathEstablished)
|
|
|
|
|
{
|
|
|
|
|
intro.latency = llarp_time_now_ms() - m_LastLatencyTestTime;
|
|
|
|
|
intro.latency = now - m_LastLatencyTestTime;
|
|
|
|
|
llarp::LogDebug("path latency is ", intro.latency,
|
|
|
|
|
" ms for tx=", TXID(), " rx=", RXID());
|
|
|
|
|
m_LastLatencyTestID = 0;
|
|
|
|
|