]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUG/MINOR: stats: Don't replace sc_shutr() by SE_FL_EOS flag yet
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 28 Mar 2023 10:02:03 +0000 (12:02 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Tue, 28 Mar 2023 12:36:05 +0000 (14:36 +0200)
In commit c2c043ed4 ("BUG/MEDIUM: stats: Consume the request except when
parsing the POST payload"), a change about applet was pushed too early. The
applet must still call cf_shutr() when the response is fully sent. It is
planned to rely on SE_FL_EOS flag, just like connections. But it is not
possible for now.

However, at first glance, this bug has no visible effect.

It is 2.8-specific. No backport needed.

src/stats.c

index edee3aaf5e7a2b18d8243a73e61206866f83f31a..3e1b90b1f0269a036b14ff8189b50107c306c14b 100644 (file)
@@ -4506,7 +4506,8 @@ static void http_stats_io_handler(struct appctx *appctx)
        }
 
        if (appctx->st0 == STAT_HTTP_END) {
-               se_fl_set(appctx->sedesc, SE_FL_EOS);
+               if (!(res->flags & CF_SHUTR))
+                       sc_shutr(sc);
                applet_will_consume(appctx);
        }