Mercurial > dovecot > original-hg > dovecot-1.2
changeset 8391:2a9d0bfc2c2b HEAD
virtual mailboxes: Fixed an assert-crash when mailbox was being opened.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Tue, 11 Nov 2008 22:01:51 +0200 |
parents | db0c70913765 |
children | 3b6999dc112f |
files | src/plugins/virtual/virtual-sync.c |
diffstat | 1 files changed, 10 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/plugins/virtual/virtual-sync.c Fri Nov 07 16:29:42 2008 +0200 +++ b/src/plugins/virtual/virtual-sync.c Tue Nov 11 22:01:51 2008 +0200 @@ -974,8 +974,16 @@ else { /* exists - update uidmap and flags */ uidmap[j++].virtual_uid = vuid; - virtual_sync_external_flags(ctx, bbox, vseq, - vrec->real_uid); + /* if ctx->retry is set, we're just opening the virtual + mailbox and using a continued search using modseq. + some messages in uidmap may already be expunged, so + we can't go looking at the real messages yet. + after retrying the sync we'll get back here and + really do it. */ + if (!ctx->retry) { + virtual_sync_external_flags(ctx, bbox, vseq, + vrec->real_uid); + } } } i_free(vmails);