From: Aurelien DARRAGON Date: Thu, 2 Feb 2023 17:13:30 +0000 (+0100) Subject: BUG/MINOR: stats: fix show stats field ctx for servers X-Git-Tag: v2.8-dev4~38 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=28a23617cebbb0c516eeec944e18ba20db72184f;p=thirdparty%2Fhaproxy.git BUG/MINOR: stats: fix show stats field ctx for servers In ("MINOR: stats: introduce stats field ctx"), we forgot to apply the patch to servers. This prevents "BUG/MINOR: stats: fix show stat json buffer limitation" from working with servers dump. We're adding the missing part related to servers dump. This commit should be backported with the aforementioned commits. --- diff --git a/src/stats.c b/src/stats.c index 5be66d4840..7bd42ed961 100644 --- a/src/stats.c +++ b/src/stats.c @@ -3311,7 +3311,10 @@ more: if (stats_dump_sv_stats(sc, px, sv)) { if (!stats_putchk(rep, htx)) goto full; + if (ctx->field) + goto more; } + current_field = 0; } /* for sv */ ctx->px_st = STAT_PX_ST_BE;