From 47424df417dcbeec9e6415a85176299604b0fde2 Mon Sep 17 00:00:00 2001 From: Adam Ierymenko Date: Mon, 9 Nov 2015 13:39:06 -0800 Subject: Fix (1) a deadlock bug and (2) a bug that prevented distributed rendezvous messages from being sent. --- node/Switch.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'node/Switch.cpp') diff --git a/node/Switch.cpp b/node/Switch.cpp index 7caf8ba6..dcaf7ebd 100644 --- a/node/Switch.cpp +++ b/node/Switch.cpp @@ -720,7 +720,8 @@ void Switch::_handleRemotePacketHead(const InetAddress &localAddr,const InetAddr Mutex::Lock _l(_lastUniteAttempt_m); uint64_t &luts = _lastUniteAttempt[_LastUniteKey(source,destination)]; shouldUnite = ((now - luts) >= ZT_MIN_UNITE_INTERVAL); - luts = now; + if (shouldUnite) + luts = now; } RR->cluster->sendViaCluster(source,destination,packet->data(),packet->size(),shouldUnite); return; -- cgit v1.2.3