From 2c02817ff6dfd5d7c67e07ea5121562f3cf38834 Mon Sep 17 00:00:00 2001 From: Brendan Cully Date: Wed, 9 Aug 2006 00:38:49 +0000 Subject: [PATCH] Do not allow IMAP mailbox to be reopened while it is being opened. --- imap/message.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/imap/message.c b/imap/message.c index 76bd3165..bef97d7e 100644 --- a/imap/message.c +++ b/imap/message.c @@ -115,7 +115,7 @@ int imap_read_headers (IMAP_DATA* idata, int msgbegin, int msgend) mx_alloc_memory (idata->ctx); oldmsgcount = ctx->msgcount; - idata->reopen &= ~IMAP_NEWMAIL_PENDING; + idata->reopen &= ~(IMAP_REOPEN_ALLOW|IMAP_NEWMAIL_PENDING); idata->newMailCount = 0; #if USE_HCACHE @@ -354,6 +354,7 @@ int imap_read_headers (IMAP_DATA* idata, int msgbegin, int msgend) mx_update_context (ctx, ctx->msgcount - oldmsgcount); } + idata->reopen |= IMAP_REOPEN_ALLOW; return msgend; } -- 2.40.0