summaryrefslogtreecommitdiff
path: root/source4/ntvfs/posix/pvfs_util.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2009-08-05 17:51:21 +1000
committerAndrew Tridgell <tridge@samba.org>2009-08-05 17:51:58 +1000
commit00a8ff5fe9acf965395b99b39b0c24a5517b6e2b (patch)
treef544527da4c973658174926191ef630d79208e58 /source4/ntvfs/posix/pvfs_util.c
parent0a16265bc21e6f1f8cef4f38b7b45f3fd356527c (diff)
downloadsamba-00a8ff5fe9acf965395b99b39b0c24a5517b6e2b.tar.gz
samba-00a8ff5fe9acf965395b99b39b0c24a5517b6e2b.tar.bz2
samba-00a8ff5fe9acf965395b99b39b0c24a5517b6e2b.zip
fixed a problem with group policy writes causing policy corruption
This bug was caused by two things: 1) in the unix ACL mapping, we were not taking into account group write permssions for the SEC_STD_DELETE flag 2) when a file is created using OVERWRITE mode, a fchmod() would fail if the user is not the file owner. We resolve that by only doing the fchmod() if the mapped file attribute does not match the desired file attribute
Diffstat (limited to 'source4/ntvfs/posix/pvfs_util.c')
-rw-r--r--source4/ntvfs/posix/pvfs_util.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source4/ntvfs/posix/pvfs_util.c b/source4/ntvfs/posix/pvfs_util.c
index 81ff20a608..b1b0a64789 100644
--- a/source4/ntvfs/posix/pvfs_util.c
+++ b/source4/ntvfs/posix/pvfs_util.c
@@ -39,7 +39,10 @@ bool pvfs_has_wildcard(const char *str)
*/
NTSTATUS pvfs_map_errno(struct pvfs_state *pvfs, int unix_errno)
{
- return map_nt_error_from_unix(unix_errno);
+ NTSTATUS status;
+ status = map_nt_error_from_unix(unix_errno);
+ DEBUG(10,(__location__ " mapped unix errno %d -> %s\n", unix_errno, nt_errstr(status)));
+ return status;
}