]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
doveadm auth: If we can't connect to auth socket, die instead of hanging.
authorTimo Sirainen <tss@iki.fi>
Wed, 26 May 2010 18:13:19 +0000 (19:13 +0100)
committerTimo Sirainen <tss@iki.fi>
Wed, 26 May 2010 18:13:19 +0000 (19:13 +0100)
--HG--
branch : HEAD

src/doveadm/doveadm-auth.c

index a9914553e330ed51928f52f5c4fd93d43ccac630..f50aecd6a7a3123c1d487362c395f03ab6deee3d 100644 (file)
@@ -137,7 +137,8 @@ cmd_auth_input(const char *auth_socket_path, struct authtest_input *input)
        client = auth_client_init(auth_socket_path, getpid(), FALSE);
        auth_client_set_connect_notify(client, auth_connected, input);
 
-       io_loop_run(current_ioloop);
+       if (auth_client_is_connected(client))
+               io_loop_run(current_ioloop);
 
        auth_client_set_connect_notify(client, NULL, NULL);
        auth_client_deinit(&client);