From: Willy Tarreau Date: Tue, 1 Jun 2010 17:45:06 +0000 (+0200) Subject: [BUG] client: always ensure to zero rep->analysers X-Git-Tag: v1.5-dev8~610 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e29e1c5df47ad7f6f052422e92e1a94bf444d2dc;p=thirdparty%2Fhaproxy.git [BUG] client: always ensure to zero rep->analysers The response analyser was not emptied upon creation of a new session. In fact it was always zero just because last session leaved it in a zero state, but in case of shared pools this cannot be guaranteed. The net effect is that it was possible to have some HTTP (or any other) analysers on the response path of a stats unix socket, which would reject the response. This fix must be backported to 1.4. --- diff --git a/src/client.c b/src/client.c index 444d47fb56..be0c90268e 100644 --- a/src/client.c +++ b/src/client.c @@ -413,6 +413,7 @@ int event_accept(int fd) { s->rep->prod = &s->si[1]; s->rep->cons = &s->si[0]; s->si[0].ob = s->si[1].ib = s->rep; + s->rep->analysers = 0; s->rep->rto = s->be->timeout.server; s->rep->wto = s->fe->timeout.client; diff --git a/src/proto_uxst.c b/src/proto_uxst.c index 91b394489e..eb4a53dd00 100644 --- a/src/proto_uxst.c +++ b/src/proto_uxst.c @@ -514,6 +514,7 @@ int uxst_event_accept(int fd) { s->rep->prod = &s->si[1]; s->rep->cons = &s->si[0]; s->si[0].ob = s->si[1].ib = s->rep; + s->rep->analysers = 0; s->rep->rto = TICK_ETERNITY; s->rep->cto = TICK_ETERNITY;