]> git.kaiwu.me - haproxy.git/commit
MINOR: http-htx: Really test the EOM flag presence in internal.htx.has_eom
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 15 Sep 2026 12:00:58 +0000 (14:00 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 18 Sep 2026 15:05:19 +0000 (17:05 +0200)
commit753d0e4d10327927384a9d3d5ff2b44077a11c86
tree7c6da5d0e440cc985807de87e89519291f2e1130
parent8912b826186b29ae26fdc0aa33055581d7d9abf2
MINOR: http-htx: Really test the EOM flag presence in internal.htx.has_eom

The "internal.htx.has_eom" sample fetch is documented to return true if the
HTX message contains the end-of-message flag. It relied on htx_msg_ended()
to do so. But this function now also reports the end of the message when the
block carrying the flag was already consumed, which is the case when the
tail block is a RAW_DATA block.

Because this sample fetch is a debugging helper, it must really answer the
question it is documented for. So the HTX message is now scanned, looking for
a block carrying the flag. Note the scan is performed from the head on
purpose. This way, no assumption is made about the position of the block
carrying the flag and an unexpected one would be reported.

The documentation was updated to mention the flag may already have been
consumed, in which case false is returned while the end of the message was
already reached.
doc/configuration.txt
src/http_htx.c