dovecot: Added MAIL_STORAGE_FLAG_NFS_FLUSH_STORAGE and
dovecot at dovecot.org
dovecot at dovecot.org
Fri Jul 13 00:18:32 EEST 2007
details: http://hg.dovecot.org/dovecot/rev/fe9da9c92cf4
changeset: 5973:fe9da9c92cf4
user: Timo Sirainen <tss at iki.fi>
date: Thu Jul 12 23:56:13 2007 +0300
description:
Added MAIL_STORAGE_FLAG_NFS_FLUSH_STORAGE and
MAIL_STORAGE_FLAG_NFS_FLUSH_INDEX flags. Pass FLUSH_INDEX to index open
flags.
diffstat:
2 files changed, 6 insertions(+), 1 deletion(-)
src/lib-storage/index/index-storage.c | 2 ++
src/lib-storage/mail-storage.h | 5 ++++-
diffs (27 lines):
diff -r 9fb9dc4d8df8 -r fe9da9c92cf4 src/lib-storage/index/index-storage.c
--- a/src/lib-storage/index/index-storage.c Thu Jul 12 23:55:08 2007 +0300
+++ b/src/lib-storage/index/index-storage.c Thu Jul 12 23:56:13 2007 +0300
@@ -367,6 +367,8 @@ void index_storage_mailbox_open(struct i
index_flags |= MAIL_INDEX_OPEN_FLAG_MMAP_DISABLE;
if ((storage->flags & MAIL_STORAGE_FLAG_DOTLOCK_USE_EXCL) != 0)
index_flags |= MAIL_INDEX_OPEN_FLAG_DOTLOCK_USE_EXCL;
+ if ((storage->flags & MAIL_STORAGE_FLAG_NFS_FLUSH_INDEX) != 0)
+ index_flags |= MAIL_INDEX_OPEN_FLAG_NFS_FLUSH;
ret = mail_index_open(ibox->index, index_flags, storage->lock_method);
if (ret <= 0 || ibox->move_to_memory) {
diff -r 9fb9dc4d8df8 -r fe9da9c92cf4 src/lib-storage/mail-storage.h
--- a/src/lib-storage/mail-storage.h Thu Jul 12 23:55:08 2007 +0300
+++ b/src/lib-storage/mail-storage.h Thu Jul 12 23:56:13 2007 +0300
@@ -32,7 +32,10 @@ enum mail_storage_flags {
fail to create the storage. */
MAIL_STORAGE_FLAG_NO_AUTOCREATE = 0x200,
/* Rely on O_EXCL when creating dotlocks */
- MAIL_STORAGE_FLAG_DOTLOCK_USE_EXCL = 0x400
+ MAIL_STORAGE_FLAG_DOTLOCK_USE_EXCL = 0x400,
+ /* Flush NFS caches for mail storage / index */
+ MAIL_STORAGE_FLAG_NFS_FLUSH_STORAGE = 0x800,
+ MAIL_STORAGE_FLAG_NFS_FLUSH_INDEX = 0x1000,
};
enum mailbox_open_flags {
More information about the dovecot-cvs
mailing list