From e29e1c5df47ad7f6f052422e92e1a94bf444d2dc Mon Sep 17 00:00:00 2001 From: Willy Tarreau Date: Tue, 1 Jun 2010 19:45:06 +0200 Subject: [PATCH] [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. --- src/client.c | 1 + src/proto_uxst.c | 1 + 2 files changed, 2 insertions(+) diff --git a/src/client.c b/src/client.c index 444d47fb5..be0c90268 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 91b394489..eb4a53dd0 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;