diff --git a/include/haproxy/conn_stream.h b/include/haproxy/conn_stream.h index 82f533ac7..7f15dff13 100644 --- a/include/haproxy/conn_stream.h +++ b/include/haproxy/conn_stream.h @@ -373,18 +373,6 @@ static inline void sc_need_room(struct stconn *sc) sc->flags |= SC_FL_NEED_ROOM; } -/* Returns non-zero if the stream connector's Tx path is blocked */ -static inline int cs_tx_blocked(const struct stconn *cs) -{ - return !!sc_ep_test(cs, SE_FL_WAIT_DATA); -} - -/* Returns non-zero if the stream connector's endpoint is ready to transmit */ -static inline int cs_tx_endp_ready(const struct stconn *cs) -{ - return sc_ep_test(cs, SE_FL_WILL_CONSUME); -} - /* Report that a stream connector wants to get some data from the output buffer */ static inline void cs_want_get(struct stconn *cs) { diff --git a/include/haproxy/cs_utils.h b/include/haproxy/cs_utils.h index b53602cbf..7efe60ed2 100644 --- a/include/haproxy/cs_utils.h +++ b/include/haproxy/cs_utils.h @@ -378,7 +378,7 @@ static inline int sc_is_send_allowed(const struct stconn *sc) if (oc->flags & CF_SHUTW) return 0; - return cs_tx_endp_ready(sc) && !cs_tx_blocked(sc); + return (sc_ep_get(sc) & (SE_FL_WAIT_DATA|SE_FL_WILL_CONSUME)) == SE_FL_WILL_CONSUME; } #endif /* _HAPROXY_CS_UTILS_H */