Mercurial > dovecot > core-2.2
changeset 10588:f4e64cb17aea HEAD
lib-master: Don't leak post-login connections.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Wed, 27 Jan 2010 21:25:44 +0200 |
parents | bea4b2d1f27f |
children | cab5f2e7b806 |
files | src/lib-master/master-login.c |
diffstat | 1 files changed, 4 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-master/master-login.c Wed Jan 27 18:49:46 2010 +0200 +++ b/src/lib-master/master-login.c Wed Jan 27 21:25:44 2010 +0200 @@ -345,7 +345,6 @@ struct master_login_client *client; struct master_login *login = conn->login; unsigned char data[MASTER_AUTH_MAX_DATA_SIZE]; - unsigned int request_count; int ret, client_fd; ret = master_login_conn_read_request(conn, &req, data, &client_fd); @@ -369,9 +368,6 @@ master_login_auth_request(login->auth, &req, master_login_auth_callback, client); - request_count = master_login_auth_request_count(login->auth); - if (login->service->master_status.available_count <= request_count) - io_remove(&conn->io); } void master_login_add(struct master_login *login, int fd) @@ -386,8 +382,10 @@ DLLIST_PREPEND(&login->conns, conn); - /* don't accept more connections. this is mainly a temporary - workaround.. */ + /* FIXME: currently there's a separate connection for each request. + and currently we don't try to accept more connections until this + request's authentication is finished, because updating + available_count gets tricky. */ master_service_io_listeners_remove(login->service); }