]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
auth: Fix return value of auth worker input processing callback
authorKarl Fleischmann <karl.fleischmann@open-xchange.com>
Mon, 28 Mar 2022 12:39:18 +0000 (14:39 +0200)
committertimo.sirainen <timo.sirainen@open-xchange.com>
Mon, 28 Mar 2022 15:46:35 +0000 (15:46 +0000)
Fix return value of input args callback in shutdown/restart cases to
stop further input processing.

src/auth/auth-worker-connection.c

index 3de488df3e03c013f41a66cfa31935fc10d09aae..0794b7694d023bcabe481eb8612d1985e9105d8c 100644 (file)
@@ -433,11 +433,13 @@ static int worker_input_args(struct connection *conn, const char *const *args)
                return -1;
        }
 
-       if (worker->restart)
+       if (worker->restart) {
                auth_worker_deinit(&worker, "Max requests limit", TRUE);
-       else if (worker->shutdown)
+               ret = 0;
+       } else if (worker->shutdown) {
                auth_worker_deinit(&worker, "Idle kill", FALSE);
-       else if (worker->request != NULL)
+               ret = 0;
+       } else if (worker->request != NULL)
                auth_worker_request_send_next(worker);
 
        return ret;