From: Willy Tarreau Date: Sun, 7 Dec 2008 12:05:04 +0000 (+0100) Subject: [BUG] do not forward close from cons to prod with analysers X-Git-Tag: v1.3.16-rc1~120 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=3dbc69494ac2b348f93ba5981c68041260ddd4e3;p=thirdparty%2Fhaproxy.git [BUG] do not forward close from cons to prod with analysers We must not forward a close from consumer to producer as long as an analyser is present. --- diff --git a/src/session.c b/src/session.c index 0df174a1c9..29ddb6f93e 100644 --- a/src/session.c +++ b/src/session.c @@ -759,7 +759,8 @@ resync_stream_interface: s->req->cons->shutw(s->req->cons); /* shutdown(write) done on server side, we must stop the client too */ - if (unlikely((s->req->flags & (BF_SHUTW|BF_SHUTR|BF_SHUTR_NOW)) == BF_SHUTW)) + if (unlikely((s->req->flags & (BF_SHUTW|BF_SHUTR|BF_SHUTR_NOW)) == BF_SHUTW && + !s->req->analysers)) buffer_shutr_now(s->req); /* shutdown(read) pending */ @@ -857,7 +858,8 @@ resync_stream_interface: s->rep->cons->shutw(s->rep->cons); /* shutdown(write) done on the client side, we must stop the server too */ - if (unlikely((s->rep->flags & (BF_SHUTW|BF_SHUTR|BF_SHUTR_NOW)) == BF_SHUTW)) + if (unlikely((s->rep->flags & (BF_SHUTW|BF_SHUTR|BF_SHUTR_NOW)) == BF_SHUTW) && + !s->rep->analysers) buffer_shutr_now(s->rep); /* shutdown(read) pending */