From: stutiredboy Date: Tue, 19 Jul 2016 03:08:55 +0000 (+0800) Subject: healthChecksThread indentation fixed. X-Git-Tag: rec-4.0.2~51^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F4198%2Fhead;p=thirdparty%2Fpdns.git healthChecksThread indentation fixed. --- diff --git a/pdns/dnsdist.cc b/pdns/dnsdist.cc index 1cf00bc107..83c0af7f90 100644 --- a/pdns/dnsdist.cc +++ b/pdns/dnsdist.cc @@ -1253,24 +1253,24 @@ void* healthChecksThread() for(auto& dss : g_dstates.getCopy()) { // this points to the actual shared_ptrs! if(dss->availability==DownstreamState::Availability::Auto) { - bool newState=upCheck(*dss); - if (newState) { - if (dss->currentCheckFailures != 0) { - dss->currentCheckFailures = 0; - } - } - else if (!newState && dss->upStatus) { - dss->currentCheckFailures++; - if (dss->currentCheckFailures < dss->maxCheckFailures) { - newState = true; - } - } - - if(newState != dss->upStatus) { - warnlog("Marking downstream %s as '%s'", dss->getNameWithAddr(), newState ? "up" : "down"); - dss->upStatus = newState; - dss->currentCheckFailures = 0; - } + bool newState=upCheck(*dss); + if (newState) { + if (dss->currentCheckFailures != 0) { + dss->currentCheckFailures = 0; + } + } + else if (!newState && dss->upStatus) { + dss->currentCheckFailures++; + if (dss->currentCheckFailures < dss->maxCheckFailures) { + newState = true; + } + } + + if(newState != dss->upStatus) { + warnlog("Marking downstream %s as '%s'", dss->getNameWithAddr(), newState ? "up" : "down"); + dss->upStatus = newState; + dss->currentCheckFailures = 0; + } } auto delta = dss->sw.udiffAndSet()/1000000.0;