Mercurial > dovecot > original-hg > dovecot-1.2
changeset 6068:dc93705c4038 HEAD
mail_index_transaction_get_next_uid(): If mail_index_reset() was called,
don't use existing next_uid (and crash).
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Wed, 18 Jul 2007 07:56:02 +0300 |
parents | f5d87227d12c |
children | 8576ce5d7fb4 |
files | src/lib-index/mail-index-transaction.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-index/mail-index-transaction.c Wed Jul 18 07:31:43 2007 +0300 +++ b/src/lib-index/mail-index-transaction.c Wed Jul 18 07:56:02 2007 +0300 @@ -431,7 +431,7 @@ unsigned int count, offset; uint32_t next_uid; - next_uid = t->view->map->hdr.next_uid; + next_uid = t->reset ? 1 : t->view->map->hdr.next_uid; if (array_is_created(&t->appends)) { /* get next_uid from appends if they have UIDs */ mail_index_transaction_sort_appends(t);