From 8055635e85beba3f0cf028cf3efe50dbf99b0cc3 Mon Sep 17 00:00:00 2001 From: Adam Ierymenko Date: Tue, 31 Dec 2013 01:22:32 -0800 Subject: VERSION 0.6.5: minor bug fix in peer connection tracking --- node/Peer.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'node') diff --git a/node/Peer.cpp b/node/Peer.cpp index 8c2c9f9b..e7db125d 100644 --- a/node/Peer.cpp +++ b/node/Peer.cpp @@ -83,18 +83,20 @@ void Peer::onReceive( _r->sw->announceMulticastGroups(SharedPtr(this)); } + // Update last receive info for our direct path + WanPath *const wp = (remoteAddr.isV4() ? &_ipv4p : &_ipv6p); + wp->lastReceive = now; + wp->localPort = ((localPort) ? localPort : Demarc::ANY_PORT); + // Do things like learn latency or endpoints on OK or ERROR replies if (inReVerb != Packet::VERB_NOP) { for(unsigned int p=0;plastReceive = now; - wp->localPort = ((localPort) ? localPort : Demarc::ANY_PORT); if (!wp->fixed) wp->addr = remoteAddr; -- cgit v1.2.3