From 4945c8a753cdfa19fdedc62049a8ee1890618706 Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Sun, 29 Jan 2017 01:06:55 +0200 Subject: [PATCH] lib-storage: Add struct mailbox_status.flags This is similar to permanent_flags, except it tells which flags can be changed at all in the session. Mainly it allows plugins to make changes to IMAP's untagged FLAGS reply. --- src/lib-storage/index/index-status.c | 1 + src/lib-storage/mail-storage.h | 2 ++ 2 files changed, 3 insertions(+) diff --git a/src/lib-storage/index/index-status.c b/src/lib-storage/index/index-status.c index d186f2849f..70dd2ab596 100644 --- a/src/lib-storage/index/index-status.c +++ b/src/lib-storage/index/index-status.c @@ -185,6 +185,7 @@ void index_storage_get_open_status(struct mailbox *box, status_r->allow_new_keywords = !box->disallow_new_keywords; } + status_r->flags = MAIL_FLAGS_NONRECENT; } } diff --git a/src/lib-storage/mail-storage.h b/src/lib-storage/mail-storage.h index b329b314cf..c0fec6f9a9 100644 --- a/src/lib-storage/mail-storage.h +++ b/src/lib-storage/mail-storage.h @@ -258,6 +258,8 @@ struct mailbox_status { /* These flags can be permanently modified (STATUS_PERMANENT_FLAGS) */ enum mail_flags permanent_flags; + /* These flags can be modified (STATUS_PERMANENT_FLAGS) */ + enum mail_flags flags; /* All keywords can be permanently modified (STATUS_PERMANENT_FLAGS) */ bool permanent_keywords:1;