BUG/MEDIUM: mux-h1: Get the session from the H1S when capturing bad messages
authorChristopher Faulet <cfaulet@haproxy.com>
Thu, 15 Oct 2020 15:19:46 +0000 (17:19 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 16 Oct 2020 17:53:17 +0000 (19:53 +0200)
commitdb2c17da60e80091615ddbe8d97cb964d1f00ac7
treeb867b36e97a57813d661e9a1ba94696b557dcff6
parent2469eba20fdc01f8ca95726a8c11feaaa8825027
BUG/MEDIUM: mux-h1: Get the session from the H1S when capturing bad messages

It is not guaranteed that the backend connection has an owner. It is set when
the connection is created. But when the connection is moved in a server idle
list, the connection owner is set to NULL and may never be set again. On the
other hand, when a mux is created or when a CS is attached, the session is
always defined. The H1 stream always keep a reference on it when it is
created. Thus, when a bad message is captured we should not rely on the
connection owner to retrieve the session. Instead we should get it from the H1
stream.
src/mux_h1.c