mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-09-23 06:41:32 +02:00
CLEANUP: config: Don't alter listener->maxaccept when nbproc is set to 1
This patch only removes a useless calculation on listener->maxaccept when nbproc is set to 1. Indeed, the following formula has no effet in such case: listener->maxaccept = (listener->maxaccept + nbproc - 1) / nbproc; This patch may be backported as far as 1.5.
This commit is contained in:
parent
6b02ab8734
commit
02f3cf19ed
@ -3728,9 +3728,8 @@ out_uri_auth_compat:
|
|||||||
* is bound to. Rememeber that maxaccept = -1 must be kept as it is
|
* is bound to. Rememeber that maxaccept = -1 must be kept as it is
|
||||||
* used to disable the limit.
|
* used to disable the limit.
|
||||||
*/
|
*/
|
||||||
if (listener->maxaccept > 0) {
|
if (listener->maxaccept > 0 && nbproc > 1) {
|
||||||
if (nbproc > 1)
|
listener->maxaccept = (listener->maxaccept + 1) / 2;
|
||||||
listener->maxaccept = (listener->maxaccept + 1) / 2;
|
|
||||||
listener->maxaccept = (listener->maxaccept + nbproc - 1) / nbproc;
|
listener->maxaccept = (listener->maxaccept + nbproc - 1) / nbproc;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user