[MEDIUM] move QUEUE and TAR timers to stream interfaces
It was not practical to have QUEUE and TAR timers in buffers, as they caused
triggering of the timeout flags. Move them to the stream interface where they
belong.
diff --git a/src/client.c b/src/client.c
index 953e41e..32e90ba 100644
--- a/src/client.c
+++ b/src/client.c
@@ -170,19 +170,21 @@
s->cli_state = CL_STDATA;
s->req = s->rep = NULL; /* will be allocated later */
- s->si[0].state = SI_ST_EST;
+ s->si[0].state = s->si[0].prev_state = SI_ST_EST;
s->si[0].err_type = SI_ET_NONE;
s->si[0].err_loc = NULL;
s->si[0].owner = t;
s->si[0].shutw = stream_sock_shutw;
s->si[0].fd = cfd;
+ s->si[0].exp = TICK_ETERNITY;
s->cli_fd = cfd;
- s->si[1].state = SI_ST_INI;
+ s->si[1].state = s->si[1].prev_state = SI_ST_INI;
s->si[1].err_type = SI_ET_NONE;
s->si[1].err_loc = NULL;
s->si[1].owner = t;
s->si[1].shutw = stream_sock_shutw;
+ s->si[1].exp = TICK_ETERNITY;
s->si[1].fd = -1; /* just to help with debugging */
s->srv = s->prev_srv = s->srv_conn = NULL;