changeset 8115:8ac8713b1386 HEAD

mail_index_lookup_seq*() could have returned wrong sequences with transaction views. This caused assert-crashes in recent flag handling for mbox and maildir.
author Timo Sirainen <tss@iki.fi>
date Thu, 28 Aug 2008 09:33:37 +0300
parents 74153b8e63a6
children 827c3a3a1627
files src/lib-index/mail-index-transaction-view.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib-index/mail-index-transaction-view.c	Wed Aug 27 19:21:12 2008 +0300
+++ b/src/lib-index/mail-index-transaction-view.c	Thu Aug 28 09:33:37 2008 +0300
@@ -127,9 +127,9 @@
 	if (*first_seq_r == 0) {
 		seq = tview->t->first_new_seq;
 		for (; seq <= tview->t->last_new_seq; seq++) {
+			rec = mail_index_transaction_lookup(tview->t, seq);
 			if (first_uid <= rec->uid)
 				break;
-			rec = mail_index_transaction_lookup(tview->t, seq);
 		}
 		if (seq > tview->t->last_new_seq) {
 			/* no messages in range */