summaryrefslogtreecommitdiffstats
path: root/imap
diff options
context:
space:
mode:
authorThomas Roessler <roessler@does-not-exist.org>2001-07-24 06:42:06 +0000
committerThomas Roessler <roessler@does-not-exist.org>2001-07-24 06:42:06 +0000
commite8a5ab461ff17be907f1364b126a99d17a982ad1 (patch)
tree7a39d14f92f66bd55d59f14b7dba2a16793e656c /imap
parentec331900088d113e555244c2f63be908a53e5c72 (diff)
The attached patch fixes a couple bugs I introduced recently when
working around the buggy but firmly entrenched UW-IMAP 4.7 server. These resulted in additional overhead when synchronising mailboxes and occasional problems opening empty mailboxes. From: Brendan Cully <brendan@kublai.com>
Diffstat (limited to 'imap')
-rw-r--r--imap/imap.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/imap/imap.c b/imap/imap.c
index 046d1c2a..dc575ea5 100644
--- a/imap/imap.c
+++ b/imap/imap.c
@@ -526,9 +526,10 @@ int imap_open_mailbox (CONTEXT* ctx)
idata->ctx = ctx;
- /* clear status, ACL */
+ /* clear mailbox status */
idata->status = 0;
memset (idata->rights, 0, (RIGHTSMAX+7)/8);
+ idata->newMailCount = 0;
mutt_message (_("Selecting %s..."), idata->mailbox);
imap_munge_mbox_name (buf, sizeof(buf), idata->mailbox);
@@ -933,7 +934,7 @@ int imap_sync_mailbox (CONTEXT* ctx, int expunge, int* index_hint)
/* save status changes */
for (n = 0; n < ctx->msgcount; n++)
{
- if (ctx->hdrs[n]->changed)
+ if (ctx->hdrs[n]->active && ctx->hdrs[n]->changed)
{
ctx->hdrs[n]->changed = 0;