]> git.kaiwu.me - haproxy.git/commit
BUG/MEDIUM: proxy: protect "show servers ..." against server deletion
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Tue, 21 Jul 2026 07:26:22 +0000 (09:26 +0200)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Tue, 21 Jul 2026 14:58:20 +0000 (16:58 +0200)
commit282ac06d81462b0f78fb5cf7972ab567b123e575
tree29af209e194e1760dc324e1ecaaea67ab1c603a1
parentc5686480aa3e2464056f4d92bd8757d9f50ebf99
BUG/MEDIUM: proxy: protect "show servers ..." against server deletion

Command show servers conn/state loops over a server list to display
various information. This command may yield in case of a large output.
This can cause a crash if the server on which the command was paused is
deleted prior to restarting the command.

Fixes this by using the watcher mechanism, similar to what is already
implementing with stats dump.

This must be backported at least up to 3.0. For older releases, watcher
mechanism is not available, server refcount + SRV_F_DELETED flag must be
used instead.
src/proxy.c