]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
[BUG] reserve some pipes for backends with splice enabled
authorWilly Tarreau <w@1wt.eu>
Sun, 25 Jan 2009 09:42:05 +0000 (10:42 +0100)
committerWilly Tarreau <w@1wt.eu>
Sun, 25 Jan 2009 09:42:05 +0000 (10:42 +0100)
If splicing is enabled in a backend, we need to guess how many
pipes will be needed. We used to rely on fullconn, but this leads
to non-working splicing when fullconn is not specified. So we now
fallback to global.maxconn.

src/haproxy.c

index 5911b0c6cdc0dce397001c0a8299d49a0d4186e6..9b83146e63772e07755239bb97224d52ac9193ea 100644 (file)
@@ -560,7 +560,7 @@ void init(int argc, char **argv)
                                if (cur->cap & PR_CAP_FE)
                                        nbfe += cur->maxconn;
                                if (cur->cap & PR_CAP_BE)
-                                       nbbe += cur->fullconn;
+                                       nbbe += cur->fullconn ? cur->fullconn : global.maxconn;
                        }
                }
                global.maxpipes = MAX(nbfe, nbbe);