mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2026-05-04 20:46:11 +02:00
MEDIUM: stream-interface: the polling flags must always be updated in chk_snd_conn
We used to only update the polling flags in data phase, but after that we could update other flags. It does not seem possible to trigger a bug here but it's not very safe either. Better always keep them up to date.
This commit is contained in:
parent
fd803bb4d7
commit
708e717251
@ -980,15 +980,13 @@ static void stream_int_chk_snd_conn(struct stream_interface *si)
|
||||
return;
|
||||
}
|
||||
|
||||
/* Before calling the data-level operations, we have to prepare
|
||||
* the polling flags to ensure we properly detect changes.
|
||||
*/
|
||||
conn_refresh_polling_flags(conn);
|
||||
__conn_data_want_send(conn);
|
||||
|
||||
if (!(conn->flags & (CO_FL_HANDSHAKE|CO_FL_WAIT_L4_CONN|CO_FL_WAIT_L6_CONN))) {
|
||||
/* Before calling the data-level operations, we have to prepare
|
||||
* the polling flags to ensure we properly detect changes.
|
||||
*/
|
||||
if (conn_ctrl_ready(conn))
|
||||
fd_want_send(conn->t.sock.fd);
|
||||
|
||||
conn_refresh_polling_flags(conn);
|
||||
|
||||
si_conn_send(conn);
|
||||
if (conn_ctrl_ready(conn) && (conn->flags & CO_FL_ERROR)) {
|
||||
/* Write error on the file descriptor */
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user