From 5f8714a0cd9f208ea6f822b2683f80596f20d67f Mon Sep 17 00:00:00 2001 From: Joseph Henry Date: Wed, 14 Oct 2020 18:40:20 -0700 Subject: [PATCH] Remove minor non-functional flow hashing stubs --- node/Bond.cpp | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/node/Bond.cpp b/node/Bond.cpp index aa8a5a426..133a3700f 100644 --- a/node/Bond.cpp +++ b/node/Bond.cpp @@ -233,12 +233,10 @@ void Bond::recordOutgoingPacket(const SharedPtr &path, const uint64_t pack } } } - if (_allowFlowHashing) { - if (_allowFlowHashing && (flowId != ZT_QOS_NO_FLOW)) { - Mutex::Lock _l(_flows_m); - if (_flows.count(flowId)) { - _flows[flowId]->recordOutgoingBytes(payloadLength); - } + if (_allowFlowHashing && (flowId != ZT_QOS_NO_FLOW)) { + Mutex::Lock _l(_flows_m); + if (_flows.count(flowId)) { + _flows[flowId]->recordOutgoingBytes(payloadLength); } } } @@ -1164,18 +1162,13 @@ void Bond::processBalanceTasks(const int64_t now) * Tasks specific to (Balance Round Robin) */ if (_bondingPolicy == ZT_BONDING_POLICY_BALANCE_RR) { - if (_allowFlowHashing) { - // TODO: Should ideally failover from (idx) to a random link, this is so that (idx+1) isn't overloaded - } - else if (!_allowFlowHashing) { - // Nothing - } + // Nothing } /** * Tasks specific to (Balance XOR) */ if (_bondingPolicy == ZT_BONDING_POLICY_BALANCE_XOR) { - // Nothing specific for XOR + // Nothing } /** * Tasks specific to (Balance Aware)