dovecot-1.2: acl: Don't assert-crash if removing all rights.
dovecot at dovecot.org
dovecot at dovecot.org
Tue Jun 16 02:40:45 EEST 2009
details: http://hg.dovecot.org/dovecot-1.2/rev/01fae3737994
changeset: 9127:01fae3737994
user: Timo Sirainen <tss at iki.fi>
date: Mon Jun 15 19:38:30 2009 -0400
description:
acl: Don't assert-crash if removing all rights.
diffstat:
1 file changed, 2 insertions(+), 1 deletion(-)
src/plugins/acl/acl-backend-vfile.c | 3 ++-
diffs (13 lines):
diff -r b745911012bb -r 01fae3737994 src/plugins/acl/acl-backend-vfile.c
--- a/src/plugins/acl/acl-backend-vfile.c Mon Jun 15 00:01:39 2009 -0400
+++ b/src/plugins/acl/acl-backend-vfile.c Mon Jun 15 19:38:30 2009 -0400
@@ -900,7 +900,8 @@ static bool modify_right_list(pool_t poo
array_append(&rights, &old_rights[i], 1);
}
new_rights = &null;
- modify_rights = array_idx(&rights, 0);
+ modify_rights = array_count(&rights) == 0 ? NULL :
+ array_idx(&rights, 0);
acl_rights_merge(pool, &new_rights, modify_rights, TRUE);
break;
case ACL_MODIFY_MODE_ADD:
More information about the dovecot-cvs
mailing list