MINOR: mux-h2: consistently rely on the htx variable to detect the mode
authorWilly Tarreau <w@1wt.eu>
Thu, 31 Jan 2019 06:23:00 +0000 (07:23 +0100)
committerWilly Tarreau <w@1wt.eu>
Thu, 31 Jan 2019 07:07:17 +0000 (08:07 +0100)
commita9b7796862e2ab61745d142dde82e615407fee46
tree697da3b8a35f89070109294f6d2dde4c266eb467
parente5fcfbed5cbeba61a7de8cbe36f68f0138b95062
MINOR: mux-h2: consistently rely on the htx variable to detect the mode

In h2_frt_transfer_data(), we support both HTX and legacy modes. The
HTX mode is detected from the proxy option and sets a valid pointer
into the htx variable. Better rely on this variable in all the function
rather than testing the option again. This way the code is clearer and
even the compiler knows this pointer is valid when it's dereferenced.

This should be backported to 1.9 if the b_is_null() patch is backported.
src/mux_h2.c