dovecot-2.0: acl: Added acl_backend_nonowner_lookups_rebuild()
dovecot at dovecot.org
dovecot at dovecot.org
Fri Mar 4 18:09:33 EET 2011
details: http://hg.dovecot.org/dovecot-2.0/rev/313e9af474a4
changeset: 12638:313e9af474a4
user: Timo Sirainen <tss at iki.fi>
date: Fri Mar 04 18:08:30 2011 +0200
description:
acl: Added acl_backend_nonowner_lookups_rebuild()
diffstat:
src/plugins/acl/acl-api-private.h | 1 +
src/plugins/acl/acl-api.c | 5 +++++
src/plugins/acl/acl-api.h | 2 ++
src/plugins/acl/acl-backend-vfile-acllist.c | 8 ++++++++
src/plugins/acl/acl-backend-vfile.c | 1 +
src/plugins/acl/acl-backend-vfile.h | 1 +
6 files changed, 18 insertions(+), 0 deletions(-)
diffs (75 lines):
diff -r 20b173d061d9 -r 313e9af474a4 src/plugins/acl/acl-api-private.h
--- a/src/plugins/acl/acl-api-private.h Fri Mar 04 17:56:11 2011 +0200
+++ b/src/plugins/acl/acl-api-private.h Fri Mar 04 18:08:30 2011 +0200
@@ -21,6 +21,7 @@
const char **name_r);
void (*nonowner_lookups_iter_deinit)
(struct acl_mailbox_list_context *ctx);
+ int (*nonowner_lookups_rebuild)(struct acl_backend *backend);
struct acl_object *(*object_init)(struct acl_backend *backend,
const char *name);
diff -r 20b173d061d9 -r 313e9af474a4 src/plugins/acl/acl-api.c
--- a/src/plugins/acl/acl-api.c Fri Mar 04 17:56:11 2011 +0200
+++ b/src/plugins/acl/acl-api.c Fri Mar 04 18:08:30 2011 +0200
@@ -163,6 +163,11 @@
ctx->backend->v.nonowner_lookups_iter_deinit(ctx);
}
+int acl_backend_nonowner_lookups_rebuild(struct acl_backend *backend)
+{
+ return backend->v.nonowner_lookups_rebuild(backend);
+}
+
void acl_rights_write_id(string_t *dest, const struct acl_rights *right)
{
switch (right->id_type) {
diff -r 20b173d061d9 -r 313e9af474a4 src/plugins/acl/acl-api.h
--- a/src/plugins/acl/acl-api.h Fri Mar 04 17:56:11 2011 +0200
+++ b/src/plugins/acl/acl-api.h Fri Mar 04 18:08:30 2011 +0200
@@ -121,6 +121,8 @@
const char **name_r);
void
acl_backend_nonowner_lookups_iter_deinit(struct acl_mailbox_list_context **ctx);
+/* Force a rebuild for nonowner lookups index */
+int acl_backend_nonowner_lookups_rebuild(struct acl_backend *backend);
struct acl_object *acl_object_init_from_name(struct acl_backend *backend,
const char *name);
diff -r 20b173d061d9 -r 313e9af474a4 src/plugins/acl/acl-backend-vfile-acllist.c
--- a/src/plugins/acl/acl-backend-vfile-acllist.c Fri Mar 04 17:56:11 2011 +0200
+++ b/src/plugins/acl/acl-backend-vfile-acllist.c Fri Mar 04 18:08:30 2011 +0200
@@ -388,3 +388,11 @@
backend->iterating_acllist = FALSE;
i_free(ctx);
}
+
+int acl_backend_vfile_nonowner_lookups_rebuild(struct acl_backend *_backend)
+{
+ struct acl_backend_vfile *backend =
+ (struct acl_backend_vfile *)_backend;
+
+ return acl_backend_vfile_acllist_rebuild(backend);
+}
diff -r 20b173d061d9 -r 313e9af474a4 src/plugins/acl/acl-backend-vfile.c
--- a/src/plugins/acl/acl-backend-vfile.c Fri Mar 04 17:56:11 2011 +0200
+++ b/src/plugins/acl/acl-backend-vfile.c Fri Mar 04 18:08:30 2011 +0200
@@ -1219,6 +1219,7 @@
acl_backend_vfile_nonowner_iter_init,
acl_backend_vfile_nonowner_iter_next,
acl_backend_vfile_nonowner_iter_deinit,
+ acl_backend_vfile_nonowner_lookups_rebuild,
acl_backend_vfile_object_init,
acl_backend_vfile_object_init_parent,
acl_backend_vfile_object_deinit,
diff -r 20b173d061d9 -r 313e9af474a4 src/plugins/acl/acl-backend-vfile.h
--- a/src/plugins/acl/acl-backend-vfile.h Fri Mar 04 17:56:11 2011 +0200
+++ b/src/plugins/acl/acl-backend-vfile.h Fri Mar 04 18:08:30 2011 +0200
@@ -47,6 +47,7 @@
const char **name_r);
void
acl_backend_vfile_nonowner_iter_deinit(struct acl_mailbox_list_context *ctx);
+int acl_backend_vfile_nonowner_lookups_rebuild(struct acl_backend *backend);
int acl_backend_vfile_object_get_mtime(struct acl_object *aclobj,
time_t *mtime_r);
More information about the dovecot-cvs
mailing list