Mercurial > dovecot > original-hg > dovecot-1.2
changeset 8907:9c82d97a5431 HEAD
acl: If a global ACL file "foo" exists, don't fail when trying to access mailbox "foo/bar".
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Fri, 03 Apr 2009 13:57:13 -0400 |
parents | 3c33885a717a |
children | 9b0f83479056 |
files | src/plugins/acl/acl-backend-vfile.c |
diffstat | 1 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/src/plugins/acl/acl-backend-vfile.c Fri Apr 03 12:41:56 2009 -0400 +++ b/src/plugins/acl/acl-backend-vfile.c Fri Apr 03 13:57:13 2009 -0400 @@ -185,7 +185,7 @@ validity->last_check = ioloop_time; if (stat(path, &st) < 0) { - if (errno == ENOENT) { + if (errno == ENOENT || errno == ENOTDIR) { validity->last_mtime = VALIDITY_MTIME_NOTFOUND; return 0; } @@ -457,7 +457,7 @@ fd = nfs_safe_open(path, O_RDONLY); if (fd == -1) { - if (errno == ENOENT) { + if (errno == ENOENT || errno == ENOTDIR) { if (aclobj->aclobj.backend->debug) i_info("acl vfile: file %s not found", path); validity->last_mtime = VALIDITY_MTIME_NOTFOUND; @@ -592,7 +592,7 @@ validity->last_check = ioloop_time; if (stat(path, &st) < 0) { - if (errno == ENOENT) { + if (errno == ENOENT || errno == ENOTDIR) { /* if the file used to exist, we have to re-read it */ return validity->last_mtime != VALIDITY_MTIME_NOTFOUND; }