Mercurial > dovecot > original-hg > dovecot-1.2
changeset 6297:3f6fadbe6888 HEAD
Change "permanent" cache decisions to "temporary" when compressing. They'll
get updated back to permanent later if needed.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Mon, 13 Aug 2007 20:25:26 +0300 |
parents | 205ee38f10d1 |
children | f5782901930b |
files | src/lib-index/mail-cache-compress.c |
diffstat | 1 files changed, 7 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-index/mail-cache-compress.c Mon Aug 13 20:16:55 2007 +0300 +++ b/src/lib-index/mail-cache-compress.c Mon Aug 13 20:25:26 2007 +0300 @@ -114,6 +114,7 @@ unsigned int used_fields_count) { struct mail_cache *cache = ctx->cache; + struct mail_cache_field *field; unsigned int i, j, idx; /* Make mail_cache_header_fields_get() return the fields in @@ -134,6 +135,12 @@ cache->file_field_map[idx] = i; j++; } + + /* change permanent decisions to temporary decisions. + if they're still permanent they'll get updated later. */ + field = &cache->fields[i].field; + if (field->decision == MAIL_CACHE_DECISION_YES) + field->decision = MAIL_CACHE_DECISION_TEMP; } i_assert(j == used_fields_count);