[dovecot-cvs] dovecot/src/lib-storage/index/maildir maildir-mail.c, 1.34, 1.35

tss at dovecot.org tss at dovecot.org
Sun May 13 20:22:42 EEST 2007


Update of /var/lib/cvs/dovecot/src/lib-storage/index/maildir
In directory talvi:/tmp/cvs-serv21368/lib-storage/index/maildir

Modified Files:
	maildir-mail.c 
Log Message:
Added MAIL_ERROR_EXPUNGED. Set the error whenever expunged message is tried
to be accessed.



Index: maildir-mail.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/maildir/maildir-mail.c,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -d -r1.34 -r1.35
--- maildir-mail.c	30 Mar 2007 12:44:03 -0000	1.34
+++ maildir-mail.c	13 May 2007 17:22:40 -0000	1.35
@@ -156,7 +156,7 @@
 		fname = maildir_uidlist_lookup(mbox->uidlist, _mail->uid,
 					       &flags);
 		if (fname == NULL) {
-			_mail->expunged = TRUE;
+			mail_set_expunged(_mail);
 			return (uoff_t)-1;
 		}
 	} else {
@@ -190,7 +190,7 @@
 			fname = maildir_uidlist_lookup(mbox->uidlist,
 						       _mail->uid, &flags);
 			if (fname == NULL) {
-				_mail->expunged = TRUE;
+				mail_set_expunged(_mail);
 				return NULL;
 			}
 		} else {
@@ -224,7 +224,7 @@
 		fname = maildir_uidlist_lookup(mbox->uidlist, _mail->uid,
 					       &flags);
 		if (fname == NULL) {
-			_mail->expunged = TRUE;
+			mail_set_expunged(_mail);
 			return (uoff_t)-1;
 		}
 		path = NULL;
@@ -267,7 +267,8 @@
 	if (data->stream == NULL) {
 		data->stream = maildir_open_mail(mbox, _mail, &deleted);
 		if (data->stream == NULL) {
-			_mail->expunged = deleted;
+			if (deleted)
+				mail_set_expunged(_mail);
 			return NULL;
 		}
 	}



More information about the dovecot-cvs mailing list