kore

Kore is a web application platform for writing scalable, concurrent web based processes in C or Python.
Commits | Files | Refs | README | LICENSE | git clone https://git.kore.io/kore.git

commit 49e97ae6f81c498260780c13d5c15d45aad64588
parent 7771adbec21f0fd2063b95f989972a814a1dfc2a
Author: Joris Vink <joris@coders.se>
Date:   Wed, 17 Sep 2014 08:46:55 +0200

Call kore_connection_disconnect() when draining connections.

This way the disconnect callbacks are called properly when
workers are exiting.

Diffstat:
src/worker.c | 3+--
1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/worker.c b/src/worker.c @@ -308,8 +308,7 @@ kore_worker_entry(struct kore_worker *kw) for (c = TAILQ_FIRST(&worker_clients); c != NULL; c = cnext) { cnext = TAILQ_NEXT(c, list); net_send_flush(c); - TAILQ_REMOVE(&worker_clients, c, list); - kore_connection_remove(c); + kore_connection_disconnect(c); } for (c = TAILQ_FIRST(&disconnected); c != NULL; c = cnext) {