]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUG/MAJOR: peers: the listener's maxaccept was not set and caused loops
authorWilly Tarreau <w@1wt.eu>
Fri, 23 Nov 2012 19:08:09 +0000 (20:08 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 23 Nov 2012 19:21:37 +0000 (20:21 +0100)
Recent commit 16a214 to move the maxaccept parameter to listeners didn't
set it on the peers' listeners, resulting in the value zero being used
there. This caused a busy loop for each peers section, because no incoming
connection could be accepted.

Thanks to HervĂ© Commowick for reporting this issue.

src/cfgparse.c

index c31774320235b5a210982bc4d15533801c5193e1..9fa1881921ff15b5e8ce94f21b7d68709d22eb78 100644 (file)
@@ -7135,6 +7135,7 @@ out_uri_auth_compat:
                while (*last) {
                        curpeers = *last;
                        if (curpeers->peers_fe) {
+                               LIST_NEXT(&curpeers->peers_fe->conf.listeners, struct listener *, by_fe)->maxaccept = 1;
                                last = &curpeers->next;
                                continue;
                        }