mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2026-03-06 15:41:36 +01:00
MINOR: sock_raw: move calls to si_data_close upper
Some users of si_data_close() need to have the fd still open, so we must move the call before fd_delete().
This commit is contained in:
parent
3788e4c874
commit
3438f5dce1
@ -710,6 +710,7 @@ static void sock_raw_shutw(struct stream_interface *si)
|
||||
/* we may have to close a pending connection, and mark the
|
||||
* response buffer as shutr
|
||||
*/
|
||||
si_data_close(si);
|
||||
fd_delete(si_fd(si));
|
||||
/* fall through */
|
||||
case SI_ST_CER:
|
||||
@ -717,7 +718,6 @@ static void sock_raw_shutw(struct stream_interface *si)
|
||||
case SI_ST_TAR:
|
||||
si->state = SI_ST_DIS;
|
||||
|
||||
si_data_close(si);
|
||||
if (si->release)
|
||||
si->release(si);
|
||||
default:
|
||||
@ -748,11 +748,11 @@ static void sock_raw_shutr(struct stream_interface *si)
|
||||
return;
|
||||
|
||||
if (si->ob->flags & BF_SHUTW) {
|
||||
si_data_close(si);
|
||||
fd_delete(si_fd(si));
|
||||
si->state = SI_ST_DIS;
|
||||
si->exp = TICK_ETERNITY;
|
||||
|
||||
si_data_close(si);
|
||||
if (si->release)
|
||||
si->release(si);
|
||||
return;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user