]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-storage: mail-storage-service: Fix failure prefix composition in mail_storage_ser...
authorStephan Bosch <stephan.bosch@dovecot.fi>
Sun, 6 Jan 2019 11:11:26 +0000 (12:11 +0100)
committerTimo Sirainen <timo.sirainen@open-xchange.com>
Thu, 21 Mar 2019 07:26:08 +0000 (07:26 +0000)
It produced a prefix without the required ": " suffix and in one case it
produced a spurious comma.

src/lib-storage/mail-storage-service.c

index 2db2606a011a80046c45863975e16bc08747f6f5..fd4dfcc9ae396f75a56cc771e4bfe2b2c7828aac 100644 (file)
@@ -1415,7 +1415,7 @@ int mail_storage_service_lookup(struct mail_storage_service_ctx *ctx,
                        input->session_id != NULL ? input->session_id :
                        (input->session_id_prefix != NULL ?
                         input->session_id_prefix : NULL);
-               i_set_failure_prefix("%s(%s%s,%s)",
+               i_set_failure_prefix("%s(%s%s%s): ",
                        master_service_get_name(ctx->service), input->username,
                        session_id == NULL ? "" : t_strdup_printf(",%s", session_id),
                        input->remote_ip.family == 0 ? "" :
@@ -1425,7 +1425,7 @@ int mail_storage_service_lookup(struct mail_storage_service_ctx *ctx,
                /* we might be here because we're doing a user lookup for a
                   shared user. the log prefix is likely already usable, so
                   just append our own without replacing the whole thing. */
-               i_set_failure_prefix("%suser-lookup(%s)",
+               i_set_failure_prefix("%suser-lookup(%s)",
                                     old_log_prefix, input->username);
                update_log_prefix = FALSE;
        }