]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-lda: Remove unused mail_deliver_get_log_var_expand_table()
authorTimo Sirainen <timo.sirainen@dovecot.fi>
Thu, 9 Feb 2017 16:01:14 +0000 (18:01 +0200)
committerGitLab <gitlab@git.dovecot.net>
Tue, 14 Feb 2017 12:57:34 +0000 (14:57 +0200)
src/lib-lda/mail-deliver.c
src/lib-lda/mail-deliver.h

index 10f7cf25ae170b381bc18921efaaa385ff533fbd..cce5caaabce442c24d833c4a39f8cf46a4013b4e 100644 (file)
@@ -78,10 +78,8 @@ mail_deliver_get_log_var_expand_table_full(struct mail_deliver_context *ctx,
                psize = dec2str(size);
        if (mail_get_virtual_size(mail, &size) == 0)
                vsize = dec2str(size);
-       if (ctx != NULL) {
-               session_time = dec2str(ctx->session_time_msecs);
-               to_envelope = ctx->dest_addr;
-       }
+       session_time = dec2str(ctx->session_time_msecs);
+       to_envelope = ctx->dest_addr;
        (void)mail_get_special(mail, MAIL_FETCH_STORAGE_ID, &storage_id);
 
        const struct var_expand_table stack_tab[] = {
@@ -103,17 +101,10 @@ mail_deliver_get_log_var_expand_table_full(struct mail_deliver_context *ctx,
 
        tab = t_malloc_no0(sizeof(stack_tab));
        memcpy(tab, stack_tab, sizeof(stack_tab));
-       if (ctx != NULL)
-               mail_deliver_log_var_expand_table_update_times(ctx, tab);
+       mail_deliver_log_var_expand_table_update_times(ctx, tab);
        return tab;
 }
 
-const struct var_expand_table *
-mail_deliver_get_log_var_expand_table(struct mail *mail, const char *message)
-{
-       return mail_deliver_get_log_var_expand_table_full(NULL, mail, message);
-}
-
 const struct var_expand_table *
 mail_deliver_ctx_get_log_var_expand_table(struct mail_deliver_context *ctx,
                                          const char *message)
index 08ebfe02fe34ed2b881d8c368af6e96b72cdd3ad..36d0f36c33afd56362a35ff0402d0cc4a5f72ce8 100644 (file)
@@ -85,8 +85,6 @@ extern deliver_mail_func_t *deliver_mail;
 const struct var_expand_table *
 mail_deliver_ctx_get_log_var_expand_table(struct mail_deliver_context *ctx,
                                          const char *message);
-const struct var_expand_table *
-mail_deliver_get_log_var_expand_table(struct mail *mail, const char *message);
 void mail_deliver_log(struct mail_deliver_context *ctx, const char *fmt, ...)
        ATTR_FORMAT(2, 3);