From bca6bb7e319f3bcbfbcb05610ebc9d01626b2323 Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Mon, 24 Aug 2009 14:09:49 -0400 Subject: [PATCH] auth worker server: Don't assert-crash if the whole reply doesn't come in one packet. --HG-- branch : HEAD --- src/auth/auth-worker-server.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/auth/auth-worker-server.c b/src/auth/auth-worker-server.c index df5c5d174e..879aae7a8b 100644 --- a/src/auth/auth-worker-server.c +++ b/src/auth/auth-worker-server.c @@ -97,6 +97,7 @@ static void auth_worker_request_send(struct auth_worker_connection *conn, o_stream_sendv(conn->output, iov, 3); + i_assert(conn->request == NULL); conn->request = request; timeout_remove(&conn->to); @@ -296,7 +297,9 @@ static void worker_input(struct auth_worker_connection *conn) } } - if (conn->shutdown && conn->request == NULL) + if (conn->request != NULL) { + /* there's still a pending request */ + } else if (conn->shutdown) auth_worker_destroy(&conn, "Max requests limit", TRUE); else auth_worker_request_send_next(conn); -- 2.47.3