]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MINOR: mux-h1: Fix conditions to know whether or not we may receive data
authorChristopher Faulet <cfaulet@haproxy.com>
Thu, 5 Dec 2019 11:30:55 +0000 (12:30 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Thu, 5 Dec 2019 12:36:03 +0000 (13:36 +0100)
commit2545a0b352ffb49e68e8945c9b8ce7e633d7e8b0
tree6011381427ec72b9d70fcd79b323bf18a7cce077
parent7b109f2f8b9cb493d9f6c01f1613bc54a6f71ba3
BUG/MINOR: mux-h1: Fix conditions to know whether or not we may receive data

The h1_recv_allowed() function is inherited from the h2 multiplexer. But for the
h1, conditions to know if we may receive data are less complex because there is
no multiplexing and because data are not parsed when received. So now, following
rules are respected :

 * if an error or a shutdown for reads was detected on the connection we must
   not attempt to receive
 * if the input buffer failed to be allocated or is full, we must not try to
   receive
 * if the input processing is busy waiting for the output side, we may attempt
   to receive
 * otherwise must may not attempt to receive

This patch must be backported as far as 1.9.
src/mux_h1.c