Skip to content

Commit

Permalink
core: tcp - reset connection write flag if io_watch_chg() for pollout…
Browse files Browse the repository at this point in the history
… fails

- it can loop otherwise in trying to see if write can be done

(cherry picked from commit d36734d)
  • Loading branch information
miconda committed Sep 22, 2015
1 parent 9b1b8a7 commit 71e7e92
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions tcp_main.c
Expand Up @@ -4113,6 +4113,7 @@ inline static int handle_tcpconn_ev(struct tcp_connection* tcpconn, short ev,
if (unlikely(io_watch_chg(&io_h, tcpconn->s, POLLOUT, fd_i)==-1)){
LM_ERR("io_watch_chg(2) failed: for %p, fd %d\n",
tcpconn, tcpconn->s);
tcpconn->flags&=~F_CONN_WRITE_W;
goto error;
}
}else
Expand Down

0 comments on commit 71e7e92

Please sign in to comment.