diff options
author | Jeremy Allison <jra@samba.org> | 2001-03-15 03:19:01 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2001-03-15 03:19:01 +0000 |
commit | ae728ea761e82d6d0bd5c96e7c82f1b1115f2e24 (patch) | |
tree | da0b601ce829f81059b856fb967ba711ebeaae03 /source3/smbd | |
parent | eb9e2882d2e837f823ccb63d6b54b93f9cdf3333 (diff) | |
download | samba-ae728ea761e82d6d0bd5c96e7c82f1b1115f2e24.tar.gz samba-ae728ea761e82d6d0bd5c96e7c82f1b1115f2e24.tar.bz2 samba-ae728ea761e82d6d0bd5c96e7c82f1b1115f2e24.zip |
Last tweak (I promise :-). Fallback to returning our SID if we're a domain
member but can't get the domain sid.
Jeremy.
(This used to be commit 45e96777d0eeafbbf40759f02cd3f5e15b12c288)
Diffstat (limited to 'source3/smbd')
-rw-r--r-- | source3/smbd/posix_acls.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/source3/smbd/posix_acls.c b/source3/smbd/posix_acls.c index fe2974b235..5c0878b9ca 100644 --- a/source3/smbd/posix_acls.c +++ b/source3/smbd/posix_acls.c @@ -961,9 +961,18 @@ static canon_ace *unix_canonicalise_acl(files_struct *fsp, SMB_STRUCT_STAT *psbu other_ace->perms = unix_perms_to_acl_perms(mode, S_IROTH, S_IWOTH, S_IXOTH); } - DLIST_ADD(list_head, other_ace); - DLIST_ADD(list_head, group_ace); - DLIST_ADD(list_head, owner_ace); + if (other_ace->perms) { + DLIST_ADD(list_head, other_ace); + } else + safe_free(other_ace); + if (group_ace->perms) { + DLIST_ADD(list_head, group_ace); + } else + safe_free(group_ace); + if (owner_ace->perms) { + DLIST_ADD(list_head, owner_ace); + } else + safe_free(owner_ace); return list_head; |