summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2011-06-07 16:42:02 -0700
committerJeremy Allison <jra@samba.org>2011-06-07 16:42:02 -0700
commitcabed2fb179ea38ac93f8b9872dc3be7825d13f8 (patch)
treeeeadc3441d656601dead79d4d9a9b0d081914b2f
parentaff6c52370f853d447fc089796b0e4aa29c24d75 (diff)
downloadsamba-cabed2fb179ea38ac93f8b9872dc3be7825d13f8.tar.gz
samba-cabed2fb179ea38ac93f8b9872dc3be7825d13f8.tar.bz2
samba-cabed2fb179ea38ac93f8b9872dc3be7825d13f8.zip
Part 1 of bugfix for #8211 - "inherit owner = yes" doesn't interact correctly with "inherit permissions = yes" and POSIX ACLs
When changing ownership on a new directory make sure we also change the returned stat struct to have the correct uid.
-rw-r--r--source3/smbd/open.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source3/smbd/open.c b/source3/smbd/open.c
index d4b0934681..fedb2735fb 100644
--- a/source3/smbd/open.c
+++ b/source3/smbd/open.c
@@ -350,6 +350,8 @@ NTSTATUS change_dir_owner_to_parent(connection_struct *conn,
DEBUG(10,("change_dir_owner_to_parent: changed ownership of new "
"directory %s to parent directory uid %u.\n",
fname, (unsigned int)smb_fname_parent->st.st_ex_uid ));
+ /* Ensure the uid entry is updated. */
+ psbuf->st_ex_uid = smb_fname_parent->st.st_ex_uid;
}
chdir: