]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MEDIUM: mux-h2: Xfer rxbuf to the upper layer when creating a front stream
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 15 Dec 2020 15:56:50 +0000 (16:56 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Thu, 21 Jan 2021 14:21:12 +0000 (15:21 +0100)
commit7d013e796cef9113cc69f151fa40fd05cc637f09
treefec0ffb66701a519a9cf3f11f44d66f734d3da4b
parent8f100427c4bf56acff967e313cd9cb8d42da035d
BUG/MEDIUM: mux-h2: Xfer rxbuf to the upper layer when creating a front stream

Just like the H1 muliplexer, when a new frontend H2 stream is created, the
rxbuf is xferred to the stream at the upper layer.

Originally, it is not a bug fix, but just an api standardization. And in
fact, it fixes a crash when a h2 stream is aborted after the request parsing
but before the first call to process_stream(). It crashes since the commit
8bebd2fe5 ("MEDIUM: http-ana: Don't process partial or empty request
anymore"). It is now totally unexpected to have an HTTP stream without a
valid request. But here the stream is unable to get the request because the
client connection was aborted. Passing it during the stream creation fixes
the bug. But the true problem is that the stream-interfaces are still
relying on the connection state while only the muxes should do so.

This fix is specific for 2.4. No backport needed.
src/mux_h2.c