From: Alan T. DeKok Date: Mon, 21 Nov 2016 16:44:40 +0000 (-0500) Subject: remove unnecessary "Need 0 more connections to reach..." INFO output X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ad44db3ceb7c1a56ea8eecc4a286c5adacbf5cec;p=thirdparty%2Ffreeradius-server.git remove unnecessary "Need 0 more connections to reach..." INFO output the <= means that when the value is 0 the server keeps spewing out "Need 0 more connections to reach..." messages into the log output. this ensures messages come out only when there is a need. Manual merge of 6be96d36 --- diff --git a/src/main/connection.c b/src/main/connection.c index e2141572713..38367ee38f1 100644 --- a/src/main/connection.c +++ b/src/main/connection.c @@ -676,7 +676,7 @@ static int fr_connection_pool_check(fr_connection_pool_t *pool, REQUEST *request * have fewer than "min". When that happens, open more * connections to enforce "min". */ - if ((pool->state.num + pool->state.pending) <= pool->min) { + if ((pool->state.num + pool->state.pending) < pool->min) { spawn = pool->min - (pool->state.num + pool->state.pending); extra = 0; @@ -701,7 +701,7 @@ static int fr_connection_pool_check(fr_connection_pool_t *pool, REQUEST *request * AND we don't have enough idle connections. * Open some more. */ - } else if (idle <= pool->spare) { + } else if (idle < pool->spare) { /* * Not enough spare connections. Spawn a few. * But cap the pool size at "max"