summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--node/Node.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/node/Node.cpp b/node/Node.cpp
index be37b7c7..d72bc73f 100644
--- a/node/Node.cpp
+++ b/node/Node.cpp
@@ -206,8 +206,10 @@ public:
}
}
- if ((!p->doPingAndKeepalive(RR,_now))&&(stableEndpoint))
- p->attemptToContactAt(RR,InetAddress(),stableEndpoint,_now);
+ if ((p->alive(_now))||(upstream)) {
+ if ((!p->doPingAndKeepalive(RR,_now))&&(stableEndpoint))
+ p->attemptToContactAt(RR,InetAddress(),stableEndpoint,_now);
+ }
if (upstream)
lastReceiveFromUpstream = std::max(p->lastReceive(),lastReceiveFromUpstream);