diff options
author | Jeremy Allison <jra@samba.org> | 2000-10-28 19:38:39 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2000-10-28 19:38:39 +0000 |
commit | 1cb444057a7894ca97706fb65a756e5fdb635f81 (patch) | |
tree | e251df5cf04952b32aafa3db1c75e09b0f742f8f /source3/smbd/posix_acls.c | |
parent | 234792321c07aa59103fb7502534e6dba0ca4c08 (diff) | |
download | samba-1cb444057a7894ca97706fb65a756e5fdb635f81.tar.gz samba-1cb444057a7894ca97706fb65a756e5fdb635f81.tar.bz2 samba-1cb444057a7894ca97706fb65a756e5fdb635f81.zip |
David Lee's utmp patch (finally). Thanks David !
Jeremy.
(This used to be commit b809a2d0c81c54e917ccc0c99b3e70ea8d7ceab1)
Diffstat (limited to 'source3/smbd/posix_acls.c')
-rw-r--r-- | source3/smbd/posix_acls.c | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/source3/smbd/posix_acls.c b/source3/smbd/posix_acls.c index b463ec2479..54b45529d0 100644 --- a/source3/smbd/posix_acls.c +++ b/source3/smbd/posix_acls.c @@ -327,7 +327,7 @@ static BOOL unpack_nt_permissions(SMB_STRUCT_STAT *psbuf, uid_t *puser, gid_t *p of the mask entry as we scan the acl. ****************************************************************************/ -size_t get_num_posix_entries(acl_t posix_acl, acl_permset_t *posix_mask) +static size_t get_num_posix_entries(acl_t posix_acl, acl_permset_t *posix_mask) { size_t num_entries; acl_entry_t entry; @@ -362,7 +362,7 @@ size_t get_nt_acl(files_struct *fsp, SEC_DESC **ppdesc) { extern DOM_SID global_sid_World; SMB_STRUCT_STAT sbuf; - SEC_ACE ace_list[6]; + SEC_ACE *ace_list; DOM_SID owner_sid; DOM_SID group_sid; size_t sd_size; @@ -373,13 +373,15 @@ size_t get_nt_acl(files_struct *fsp, SEC_DESC **ppdesc) int grp_acl_type; SEC_ACCESS other_access; int other_acl_type; - int num_acls = 0; - acl_t posix_acl; + size_t num_acls = 0; + size_t num_dir_acls = 0; + acl_t posix_acl = NULL; + acl_t directory_acl = NULL; *ppdesc = NULL; if(fsp->is_directory || fsp->fd == -1) { - if(dos_stat(fsp->fsp_name, &sbuf) != 0) { + if(vfs_stat(fsp,fsp->fsp_name, &sbuf) != 0) { return 0; } /* @@ -389,6 +391,13 @@ size_t get_nt_acl(files_struct *fsp, SEC_DESC **ppdesc) if ((posix_acl = acl_get_file( dos_to_unix(fsp->fsp_name, False), ACL_TYPE_ACCESS)) == NULL) return 0; + /* + * If it's a directory get the default POSIX ACL. + */ + + if(fsp->is_directory) { + } + } else { if(fsp->conn->vfs_ops.fstat(fsp->fd,&sbuf) != 0) { return 0; |