Mercurial > dovecot > original-hg > dovecot-1.2
changeset 6982:c8df2492959e HEAD
Don't rebuild dbox if another process had done it already by the time we got
the mailbox locked.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Sun, 09 Dec 2007 16:27:17 +0200 |
parents | 66b439e24c47 |
children | 9a074ef38b02 |
files | src/lib-storage/index/dbox/dbox-sync.c |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-storage/index/dbox/dbox-sync.c Sun Dec 09 16:20:35 2007 +0200 +++ b/src/lib-storage/index/dbox/dbox-sync.c Sun Dec 09 16:27:17 2007 +0200 @@ -317,6 +317,10 @@ return ret; } + if (rebuild && dbox_sync_want_flush_dirty(mbox, FALSE) >= 0) { + /* another process rebuilt it already */ + rebuild = FALSE; + } if (rebuild) { ret = 0; rebuild = FALSE;