Commit cb50f09adcdaaf2b734c197f919316ac93b328f2
1 parent
3d735c7f
reset keep_live flag on connection close
Showing
2 changed files
with
9 additions
and
1 deletions
1 | +2012-02-10 09:59:41 +0100 Georg Hopp | ||
2 | + | ||
3 | + * reset keep_live flag on connection close (HEAD, master) | ||
4 | + | ||
1 | 2012-02-10 09:52:27 +0100 Georg Hopp | 5 | 2012-02-10 09:52:27 +0100 Georg Hopp |
2 | 6 | ||
3 | - * made a first cruel handling for keep-alive and non keep-alive requests. @TODO: this MUST BE cleaned (HEAD, master) | 7 | + * made a first cruel handling for keep-alive and non keep-alive requests. @TODO: this MUST BE cleaned |
4 | 8 | ||
5 | 2012-02-10 08:14:31 +0100 Georg Hopp | 9 | 2012-02-10 08:14:31 +0100 Georg Hopp |
6 | 10 |
@@ -10,10 +10,14 @@ serverCloseConn(Server this, unsigned int i) | @@ -10,10 +10,14 @@ serverCloseConn(Server this, unsigned int i) | ||
10 | 10 | ||
11 | delete(&((this->conns)[fd].sock)); | 11 | delete(&((this->conns)[fd].sock)); |
12 | delete(&((this->conns)[fd].reader)); | 12 | delete(&((this->conns)[fd].reader)); |
13 | + | ||
13 | memset((this->conns)[fd].wbuf, 0, strlen((this->conns)[fd].wbuf)); | 14 | memset((this->conns)[fd].wbuf, 0, strlen((this->conns)[fd].wbuf)); |
15 | + (this->conns)[fd].keep_alive = 0; | ||
16 | + | ||
14 | (this->fds)[i].events = 0; | 17 | (this->fds)[i].events = 0; |
15 | (this->fds)[i].revents = 0; | 18 | (this->fds)[i].revents = 0; |
16 | (this->fds)[i].fd = 0; | 19 | (this->fds)[i].fd = 0; |
20 | + | ||
17 | this->ndel++; | 21 | this->ndel++; |
18 | // CLEAR_CONN(this, i); | 22 | // CLEAR_CONN(this, i); |
19 | // this->nfds--; | 23 | // this->nfds--; |
Please
register
or
login
to post a comment