mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-11-28 22:31:06 +01:00
MINOR: stream-int: factor the SI_ST_EST state test into si_chk_rcv()
This test is made in each implementation of the function, better to merge it.
This commit is contained in:
parent
96aadd5c55
commit
1bdb598a55
@ -396,6 +396,9 @@ static inline void si_chk_rcv(struct stream_interface *si)
|
|||||||
if (!(si->flags & SI_FL_WANT_PUT))
|
if (!(si->flags & SI_FL_WANT_PUT))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if (si->state > SI_ST_EST)
|
||||||
|
return;
|
||||||
|
|
||||||
si->ops->chk_rcv(si);
|
si->ops->chk_rcv(si);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -248,7 +248,7 @@ static void stream_int_chk_rcv(struct stream_interface *si)
|
|||||||
__FUNCTION__,
|
__FUNCTION__,
|
||||||
si, si->state, ic->flags, si_oc(si)->flags);
|
si, si->state, ic->flags, si_oc(si)->flags);
|
||||||
|
|
||||||
if (unlikely(si->state != SI_ST_EST || (ic->flags & (CF_SHUTR|CF_DONT_READ))))
|
if (ic->flags & (CF_SHUTR|CF_DONT_READ))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (!channel_may_recv(ic) || ic->pipe) {
|
if (!channel_may_recv(ic) || ic->pipe) {
|
||||||
@ -960,7 +960,7 @@ static void stream_int_chk_rcv_conn(struct stream_interface *si)
|
|||||||
{
|
{
|
||||||
struct channel *ic = si_ic(si);
|
struct channel *ic = si_ic(si);
|
||||||
|
|
||||||
if (unlikely(si->state > SI_ST_EST || (ic->flags & CF_SHUTR)))
|
if (ic->flags & CF_SHUTR)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if ((ic->flags & CF_DONT_READ) || !channel_may_recv(ic)) {
|
if ((ic->flags & CF_DONT_READ) || !channel_may_recv(ic)) {
|
||||||
@ -1498,7 +1498,7 @@ static void stream_int_chk_rcv_applet(struct stream_interface *si)
|
|||||||
__FUNCTION__,
|
__FUNCTION__,
|
||||||
si, si->state, ic->flags, si_oc(si)->flags);
|
si, si->state, ic->flags, si_oc(si)->flags);
|
||||||
|
|
||||||
if (unlikely(si->state != SI_ST_EST || (ic->flags & (CF_SHUTR|CF_DONT_READ))))
|
if (ic->flags & (CF_SHUTR|CF_DONT_READ))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (channel_may_recv(ic) && !ic->pipe) {
|
if (channel_may_recv(ic) && !ic->pipe) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user