mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-08-07 15:47:01 +02:00
MINOR: stconn/applet: Handle EOS in the applet .wake callback function
Just like for end of input, the end of stream reported by the endpoint (SE_FL_EOS flag) is now handled in sc_applet_process(). The idea is to have applets acting as muxes by reporting events through the SE descriptor, as far as possible.
This commit is contained in:
parent
92297749e1
commit
0ffc9d7be3
@ -1829,6 +1829,11 @@ static int sc_applet_process(struct stconn *sc)
|
|||||||
ic->flags |= (CF_EOI|CF_READ_EVENT);
|
ic->flags |= (CF_EOI|CF_READ_EVENT);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (sc_ep_test(sc, SE_FL_EOS)) {
|
||||||
|
/* we received a shutdown */
|
||||||
|
sc_shutr(sc);
|
||||||
|
}
|
||||||
|
|
||||||
/* If the applet wants to write and the channel is closed, it's a
|
/* If the applet wants to write and the channel is closed, it's a
|
||||||
* broken pipe and it must be reported.
|
* broken pipe and it must be reported.
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user