MINOR: stconn: Stop to set SE_FL_ERROR on sending path
authorChristopher Faulet <cfaulet@haproxy.com>
Fri, 14 Apr 2023 07:42:59 +0000 (09:42 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 14 Apr 2023 15:05:53 +0000 (17:05 +0200)
commit56a2b608b0eac08d153151284ef01164e2f855d1
treeb5b7d0248f135689961c97e52e9aab1f3b5843ce
parentd3bc340e7ef4e47b10d04c30c794fb690e83a4d2
MINOR: stconn: Stop to set SE_FL_ERROR on sending path

It is not the SC responsibility to report errors on the SE descriptor. It is
the endpoint responsibility. It must switch SE_FL_ERR_PENDING into
SE_FL_ERROR if the end of stream was detected. It can even be considered as
a bug if it is not done by he endpoint.

So now, on sending path, a BUG_ON() is added to abort if SE_FL_EOS and
SE_FL_ERR_PENDING flags are set but not SE_FL_ERROR. It is trully important
to handle this case in the endpoint to be able to properly shut the endpoint
down.
src/stconn.c