This commit is contained in:
Adam Ierymenko 2019-08-21 10:44:52 -07:00
parent 67a9898a99
commit 5280d28505
No known key found for this signature in database
GPG key ID: 1657198823E52A61
6 changed files with 89 additions and 82 deletions

View file

@ -78,12 +78,9 @@ public:
void pushCredentials(const RuntimeEnvironment *RR,void *tPtr,const int64_t now,const Address &peerAddress,const NetworkConfig &nconf);
/**
* @return True if we haven't pushed credentials in a long time (to cause proactive credential push)
* @return Time we last pushed credentials to this member
*/
inline bool shouldPushCredentials(const int64_t now) const
{
return ((now - _lastPushedCredentials) > ZT_PEER_ACTIVITY_TIMEOUT);
}
inline int64_t lastPushedCredentials() const { return _lastPushedCredentials; }
/**
* Check whether we should push MULTICAST_LIKEs to this peer, and update last sent time if true