Fix (1) a deadlock bug and (2) a bug that prevented distributed rendezvous messages from being sent.
This commit is contained in:
@@ -395,6 +395,7 @@ void Cluster::sendViaCluster(const Address &fromPeerAddress,const Address &toPee
|
|||||||
mostRecentTs = rpe->second;
|
mostRecentTs = rpe->second;
|
||||||
mostRecentMemberId = rpe->first.second;
|
mostRecentMemberId = rpe->first.second;
|
||||||
}
|
}
|
||||||
|
++rpe;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -720,6 +720,7 @@ void Switch::_handleRemotePacketHead(const InetAddress &localAddr,const InetAddr
|
|||||||
Mutex::Lock _l(_lastUniteAttempt_m);
|
Mutex::Lock _l(_lastUniteAttempt_m);
|
||||||
uint64_t &luts = _lastUniteAttempt[_LastUniteKey(source,destination)];
|
uint64_t &luts = _lastUniteAttempt[_LastUniteKey(source,destination)];
|
||||||
shouldUnite = ((now - luts) >= ZT_MIN_UNITE_INTERVAL);
|
shouldUnite = ((now - luts) >= ZT_MIN_UNITE_INTERVAL);
|
||||||
|
if (shouldUnite)
|
||||||
luts = now;
|
luts = now;
|
||||||
}
|
}
|
||||||
RR->cluster->sendViaCluster(source,destination,packet->data(),packet->size(),shouldUnite);
|
RR->cluster->sendViaCluster(source,destination,packet->data(),packet->size(),shouldUnite);
|
||||||
|
|||||||
Reference in New Issue
Block a user