-2007-04-12 09:16 -0700 Brendan Cully <brendan@kublai.com> (eb5db1cd5251)
+2007-04-12 11:54 -0700 Brendan Cully <brendan@kublai.com> (3ee4effbb8e8)
+
+ * init.h: Make $header_cache_compress default to set
+
+ * imap/message.c: Simplify IMAP message fetch loop slightly
* imap/message.c: Handle a missing or corrupted header cache entry
(closes #2676) If imap_hcache_get fails, stop parsing the header
int deleted = ctx->deleted;
int tagged = ctx->tagged;
int flagged = ctx->flagged;
+ int update = 0;
if (ctx->readonly && flag != M_TAG)
return; /* don't modify anything if we are read-only */
if (!h->deleted && !ctx->readonly)
{
h->deleted = 1;
+ update = 1;
if (upd_ctx) ctx->deleted++;
#ifdef USE_IMAP
/* deleted messages aren't treated as changed elsewhere so that the
else if (h->deleted)
{
h->deleted = 0;
+ update = 1;
if (upd_ctx) ctx->deleted--;
#ifdef USE_IMAP
/* see my comment above */
{
if (h->read || h->old)
{
+ update = 1;
h->old = 0;
if (upd_ctx) ctx->new++;
if (h->read)
}
else if (!h->read)
{
+ update = 1;
if (!h->old)
if (upd_ctx) ctx->new--;
h->read = 1;
{
if (!h->old)
{
+ update = 1;
h->old = 1;
if (!h->read)
if (upd_ctx) ctx->new--;
}
else if (h->old)
{
+ update = 1;
h->old = 0;
if (!h->read)
if (upd_ctx) ctx->new++;
{
if (!h->read)
{
+ update = 1;
h->read = 1;
if (upd_ctx) ctx->unread--;
if (!h->old)
}
else if (h->read)
{
+ update = 1;
h->read = 0;
if (upd_ctx) ctx->unread++;
if (!h->old)
{
if (!h->replied)
{
+ update = 1;
h->replied = 1;
if (!h->read)
{
}
else if (h->replied)
{
+ update = 1;
h->replied = 0;
h->changed = 1;
if (upd_ctx) ctx->changed = 1;
{
if (!h->flagged)
{
+ update = 1;
h->flagged = bf;
if (upd_ctx) ctx->flagged++;
h->changed = 1;
}
else if (h->flagged)
{
+ update = 1;
h->flagged = 0;
if (upd_ctx) ctx->flagged--;
h->changed = 1;
{
if (!h->tagged)
{
+ update = 1;
h->tagged = 1;
if (upd_ctx) ctx->tagged++;
}
}
else if (h->tagged)
{
+ update = 1;
h->tagged = 0;
if (upd_ctx) ctx->tagged--;
}
break;
}
- mutt_set_header_color(ctx, h);
+ if (update)
+ mutt_set_header_color(ctx, h);
/* if the message status has changed, we need to invalidate the cached
* search results so that any future search will match the current status