Mercurial > dovecot > core-2.2
changeset 21549:207a5e4b7a7f
lib-lda: Remove %{storage_id} setting for now.
It doesn't work with Sieve. The following patches add it back properly.
author | Timo Sirainen <timo.sirainen@dovecot.fi> |
---|---|
date | Mon, 13 Feb 2017 20:44:31 +0200 |
parents | 22a63dda10f0 |
children | 0a4e672c70a1 |
files | src/lib-lda/mail-deliver.c |
diffstat | 1 files changed, 1 insertions(+), 19 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-lda/mail-deliver.c Fri Feb 17 11:25:49 2017 +0200 +++ b/src/lib-lda/mail-deliver.c Mon Feb 13 20:44:31 2017 +0200 @@ -65,7 +65,7 @@ { struct mail *mail; const char *message_id = NULL, *subject = NULL, *from_envelope = NULL; - const char *from, *storage_id = NULL; + const char *from; if (ctx->cache == NULL) ctx->cache = p_new(ctx->pool, struct mail_deliver_cache, 1); @@ -90,9 +90,6 @@ from_envelope = str_sanitize(from_envelope, 80); update_cache(ctx, &ctx->cache->from_envelope, from_envelope); - (void)mail_get_special(mail, MAIL_FETCH_STORAGE_ID, &storage_id); - update_cache(ctx, &ctx->cache->storage_id, storage_id); - if (mail_get_physical_size(mail, &ctx->cache->psize) < 0) ctx->cache->psize = 0; if (mail_get_virtual_size(mail, &ctx->cache->vsize) < 0) @@ -392,21 +389,6 @@ mail_free(&ctx->dest_mail); mailbox_transaction_rollback(&t); } - /* might as well get the storage_id */ - (void)mail_get_special(ctx->dest_mail, MAIL_FETCH_STORAGE_ID, - &ctx->cache->storage_id); - } else if (var_has_key(ctx->set->deliver_log_format, '\0', "storage_id")) { - /* storage ID is available only after commit. */ - struct mail *mail = mail_deliver_open_mail(box, &changes, - MAIL_FETCH_STORAGE_ID, &t); - if (mail != NULL) { - const char *str; - - (void)mail_get_special(mail, MAIL_FETCH_STORAGE_ID, &str); - ctx->cache->storage_id = t_strdup(str); - mail_free(&mail); - (void)mailbox_transaction_commit(&t); - } } mail_deliver_log(ctx, "saved mail to %s", mailbox_name); pool_unref(&changes.pool);