summaryrefslogtreecommitdiff
path: root/source3/smbd/dosmode.c
diff options
context:
space:
mode:
authorVolker Lendecke <vlendec@samba.org>2007-01-07 18:08:50 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:16:57 -0500
commitb2efff8fe5cdfd031a7b6f814993a9c234a66ee8 (patch)
treee234e62e7e034976df2e6d3ff663489d95ac46ea /source3/smbd/dosmode.c
parentbb357a1617761177475a422008a14a1ac0435eb1 (diff)
downloadsamba-b2efff8fe5cdfd031a7b6f814993a9c234a66ee8.tar.gz
samba-b2efff8fe5cdfd031a7b6f814993a9c234a66ee8.tar.bz2
samba-b2efff8fe5cdfd031a7b6f814993a9c234a66ee8.zip
r20597: Survive some of the notify mask tests.
(This used to be commit e4a2e63272dc5b20413597179d06b0185c4a6817)
Diffstat (limited to 'source3/smbd/dosmode.c')
-rw-r--r--source3/smbd/dosmode.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/source3/smbd/dosmode.c b/source3/smbd/dosmode.c
index 1172fe3e6b..a3c46b3275 100644
--- a/source3/smbd/dosmode.c
+++ b/source3/smbd/dosmode.c
@@ -499,8 +499,11 @@ int file_set_dosmode(connection_struct *conn, const char *fname,
unixmode |= (st->st_mode & (S_IWUSR|S_IWGRP|S_IWOTH));
}
- if ((ret = SMB_VFS_CHMOD(conn,fname,unixmode)) == 0)
+ if ((ret = SMB_VFS_CHMOD(conn,fname,unixmode)) == 0) {
+ notify_fname(conn, fname, FILE_NOTIFY_CHANGE_ATTRIBUTES,
+ NOTIFY_ACTION_MODIFIED);
return 0;
+ }
if((errno != EPERM) && (errno != EACCES))
return -1;
@@ -529,6 +532,8 @@ int file_set_dosmode(connection_struct *conn, const char *fname,
ret = SMB_VFS_FCHMOD(fsp, fsp->fh->fd, unixmode);
unbecome_root();
close_file_fchmod(fsp);
+ notify_fname(conn, fname, FILE_NOTIFY_CHANGE_ATTRIBUTES,
+ NOTIFY_ACTION_MODIFIED);
}
return( ret );
@@ -601,6 +606,9 @@ BOOL set_filetime(connection_struct *conn, const char *fname, time_t mtime)
DEBUG(4,("set_filetime(%s) failed: %s\n",fname,strerror(errno)));
return False;
}
+
+ notify_fname(conn, fname, FILE_NOTIFY_CHANGE_LAST_WRITE,
+ NOTIFY_ACTION_MODIFIED);
return(True);
}