summaryrefslogtreecommitdiff
path: root/node/Switch.cpp
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@gmail.com>2017-08-23 14:00:08 -0700
committerAdam Ierymenko <adam.ierymenko@gmail.com>2017-08-23 14:00:08 -0700
commit9cfc10952748487bed318ec11221eeccbb285c89 (patch)
treeed7f7d041643dd159c5be366807a08280c946562 /node/Switch.cpp
parent64758c46b672f8b3182c370aed6b81a07780c093 (diff)
downloadinfinitytier-9cfc10952748487bed318ec11221eeccbb285c89.tar.gz
infinitytier-9cfc10952748487bed318ec11221eeccbb285c89.zip
Tighten a few timings.
Diffstat (limited to 'node/Switch.cpp')
-rw-r--r--node/Switch.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/node/Switch.cpp b/node/Switch.cpp
index 053f793e..0d39bee9 100644
--- a/node/Switch.cpp
+++ b/node/Switch.cpp
@@ -630,9 +630,9 @@ unsigned long Switch::doTimerTasks(void *tPtr,uint64_t now)
{ // Time out TX queue packets that never got WHOIS lookups or other info.
Mutex::Lock _l(_txQueue_m);
for(std::list< TXQueueEntry >::iterator txi(_txQueue.begin());txi!=_txQueue.end();) {
- if (_trySend(tPtr,txi->packet,txi->encrypt))
+ if (_trySend(tPtr,txi->packet,txi->encrypt)) {
_txQueue.erase(txi++);
- else if ((now - txi->creationTime) > ZT_TRANSMIT_QUEUE_TIMEOUT) {
+ } else if ((now - txi->creationTime) > ZT_TRANSMIT_QUEUE_TIMEOUT) {
RR->t->txTimedOut(tPtr,txi->dest);
_txQueue.erase(txi++);
} else ++txi;