summaryrefslogtreecommitdiffstats
path: root/source/smbd/posix_acls.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2008-01-24 18:22:43 -0800
committerJeremy Allison <jra@samba.org>2008-01-24 18:22:43 -0800
commitc5edf7456955471b8590c2cfa67c7f47a387cdf0 (patch)
treeebc19e312a98497931f42440cdf3922dc43557ba /source/smbd/posix_acls.c
parent4d302254fdfce2c267cf6b21f662d5aa2dc9c72c (diff)
downloadsamba-c5edf7456955471b8590c2cfa67c7f47a387cdf0.tar.gz
samba-c5edf7456955471b8590c2cfa67c7f47a387cdf0.tar.xz
samba-c5edf7456955471b8590c2cfa67c7f47a387cdf0.zip
Fix the same bug with user -> user_obj.
Jeremy.
Diffstat (limited to 'source/smbd/posix_acls.c')
-rw-r--r--source/smbd/posix_acls.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/source/smbd/posix_acls.c b/source/smbd/posix_acls.c
index 9c015261b5f..f60329a039a 100644
--- a/source/smbd/posix_acls.c
+++ b/source/smbd/posix_acls.c
@@ -1474,7 +1474,13 @@ static bool create_canon_ace_lists(files_struct *fsp, SMB_STRUCT_STAT *pst,
} else if (sid_to_uid( &current_ace->trustee, &current_ace->unix_ug.uid)) {
current_ace->owner_type = UID_ACE;
- current_ace->type = SMB_ACL_USER;
+ /* If it's the owning user, this is a user_obj, not
+ * a user. */
+ if (current_ace->unix_ug.uid == pst->st_uid) {
+ current_ace->type = SMB_ACL_USER_OBJ;
+ } else {
+ current_ace->type = SMB_ACL_USER;
+ }
} else if (sid_to_gid( &current_ace->trustee, &current_ace->unix_ug.gid)) {
current_ace->owner_type = GID_ACE;
/* If it's the primary group, this is a group_obj, not