Fixed inclusion of two functions whatever ACL option selected

N2009_11_14_FIXES
jpandre 2008-12-01 15:07:49 +00:00
parent 150a7879db
commit c4c3c8f90f
2 changed files with 10 additions and 8 deletions

View File

@ -282,6 +282,8 @@ int ntfs_set_posix_acl(struct SECURITY_CONTEXT *scx, const char *path,
ntfs_inode *ni);
int ntfs_remove_posix_acl(struct SECURITY_CONTEXT *scx, const char *path,
const char *name, ntfs_inode *ni);
#endif
int ntfs_get_ntfs_acl(struct SECURITY_CONTEXT *scx, const char *path,
const char *name, char *value, size_t size,
ntfs_inode *ni);
@ -289,9 +291,6 @@ int ntfs_set_ntfs_acl(struct SECURITY_CONTEXT *scx, const char *path,
const char *name, const char *value, size_t size,
ntfs_inode *ni);
#endif
/*
* Security API for direct access to security descriptors
* based on Win32 API

View File

@ -2128,6 +2128,8 @@ int ntfs_get_posix_acl(struct SECURITY_CONTEXT *scx, const char *path,
return (outsize ? (int)outsize : -errno);
}
#endif /* POSIXACLS */
/*
* Get an NTFS ACL
*
@ -2155,8 +2157,6 @@ int ntfs_get_ntfs_acl(struct SECURITY_CONTEXT *scx, const char *path,
return (outsize ? (int)outsize : -errno);
}
#endif /* POSIXACLS */
/*
* Get owner, group and permissions in an stat structure
* returns permissions, or -1 if there is a problem
@ -2849,6 +2849,8 @@ int ntfs_remove_posix_acl(struct SECURITY_CONTEXT *scx, const char *path,
(const char*)NULL, 0, ni));
}
#endif
/*
* Set a new NTFS ACL to a file
*
@ -2867,7 +2869,11 @@ int ntfs_set_ntfs_acl(struct SECURITY_CONTEXT *scx,
if ((size > 0)
&& ntfs_valid_descr(value,size)
&& (ntfs_attr_size(value) == size)) {
#if POSIXACLS
if (ntfs_allowed_as_owner(scx,path,ni)) {
#else
{ /* relying on fuse for access control */
#endif
/* need copying in order to write */
attr = (char*)ntfs_malloc(size);
if (attr) {
@ -2908,9 +2914,6 @@ int ntfs_set_ntfs_acl(struct SECURITY_CONTEXT *scx,
return (res ? -1 : 0);
}
#endif
/*
* Set new permissions to a file
* Checks user mapping has been defined before request for setting