BUG/MINOR: stats: fix compare of no-maint url suffix
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Thu, 25 Feb 2021 13:46:08 +0000 (14:46 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 26 Feb 2021 13:13:44 +0000 (14:13 +0100)
commite78aa8776e6c4fd4c5fd56ae7b17a1d12cb390d8
treea84dabc1a5903f9c0dc1e30265cfcea3b2c8b39f
parent70da107df31963cd33d8ae3c614e3a62d74b8947
BUG/MINOR: stats: fix compare of no-maint url suffix

Only the first 3 characters are compared for ';no-maint' suffix in
http_handle_stats. Fix it by doing a full match over the entire suffix.

As a side effect, the ';norefresh' suffix matched the inaccurate
comparison, so the maintenance servers were always hidden on the stats
page in this case.

no-maint suffix is present since commit
  3e320367014c742814ba494594cdb8340b1161f1
  MINOR: stats: also support a "no-maint" show stat modifier

It should be backported up to 2.3.

This fixes github issue #1147.

(cherry picked from commit 91e55ea3f3f6277d91c0fd85ea924ea0e444f7f3)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
src/http_ana.c