changeset 6376:9b9436231ce0 HEAD

If view is inconsistent, show the mail as expunged.
author Timo Sirainen <tss@iki.fi>
date Sat, 15 Sep 2007 09:56:29 +0300
parents fc2f5607108d
children 29f427039e00
files src/lib-storage/index/index-mail.c
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib-storage/index/index-mail.c	Sat Sep 15 09:22:16 2007 +0300
+++ b/src/lib-storage/index/index-mail.c	Sat Sep 15 09:56:29 2007 +0300
@@ -978,6 +978,11 @@
 	data->seq = seq;
 	data->flags = rec->flags & MAIL_FLAGS_NONRECENT;
 
+	if (mail_index_view_is_inconsistent(mail->trans->trans_view)) {
+		mail_set_expunged(&mail->mail.mail);
+		return;
+	}
+
 	if ((mail->wanted_fields & (MAIL_FETCH_NUL_STATE |
 				    MAIL_FETCH_IMAP_BODY |
 				    MAIL_FETCH_IMAP_BODYSTRUCTURE)) != 0) {