]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
virtual: Set MAIL_STORAGE_CLASS_FLAG_NOQUOTA to storage's class_flags.
authorTimo Sirainen <tss@iki.fi>
Thu, 4 Nov 2010 18:56:13 +0000 (18:56 +0000)
committerTimo Sirainen <tss@iki.fi>
Thu, 4 Nov 2010 18:56:13 +0000 (18:56 +0000)
src/lib-storage/mail-storage-private.h
src/plugins/virtual/virtual-storage.c

index 5644c686f35ba0ef4b6762afa9b14198d2177725..720ff4dc339d5ca5a6b15c226292bc7d63dcd023 100644 (file)
@@ -54,7 +54,9 @@ enum mail_storage_class_flags {
        /* root_dir points to a unique directory */
        MAIL_STORAGE_CLASS_FLAG_UNIQUE_ROOT     = 0x02,
        /* mailbox_open_stream() is supported */
-       MAIL_STORAGE_CLASS_FLAG_OPEN_STREAMS    = 0x04
+       MAIL_STORAGE_CLASS_FLAG_OPEN_STREAMS    = 0x04,
+       /* never use quota for this storage (e.g. virtual mailboxes) */
+       MAIL_STORAGE_CLASS_FLAG_NOQUOTA         = 0x08
 };
 
 struct mail_storage {
index 3a661e72fd49155baf76be638d15a31274ac369a..910be64b0ea088d3930cd02eef39508321770390 100644 (file)
@@ -401,7 +401,6 @@ static void virtual_storage_add_list(struct mail_storage *storage ATTR_UNUSED,
        mlist->module_ctx.super = *v;
        list->vlast = &mlist->module_ctx.super;
 
-       list->ns->flags |= NAMESPACE_FLAG_NOQUOTA;
        v->get_mailbox_flags = virtual_list_get_mailbox_flags;
 
        MODULE_CONTEXT_SET(list, virtual_mailbox_list_module, mlist);
@@ -488,7 +487,7 @@ static bool virtual_is_inconsistent(struct mailbox *box)
 
 struct mail_storage virtual_storage = {
        .name = VIRTUAL_STORAGE_NAME,
-       .class_flags = 0,
+       .class_flags = MAIL_STORAGE_CLASS_FLAG_NOQUOTA,
 
        .v = {
                NULL,