summaryrefslogtreecommitdiffstats
path: root/source3/smbd/notify.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2009-04-20 16:53:02 +0200
committerAndrew Bartlett <abartlet@samba.org>2009-04-20 16:53:02 +0200
commit6c9caed48187a0d18becf59ab636af44cbe521b0 (patch)
treec47170169077be6f8ae60aed739803ab4ba861b7 /source3/smbd/notify.c
parent53765c81f726a8c056cc4e57004592dd489975c9 (diff)
parent31120c9eacafd93e0f2c6b0f906af21adadd318a (diff)
downloadsamba-6c9caed48187a0d18becf59ab636af44cbe521b0.tar.gz
samba-6c9caed48187a0d18becf59ab636af44cbe521b0.tar.xz
samba-6c9caed48187a0d18becf59ab636af44cbe521b0.zip
Merge commit 'origin/master' into libcli-auth-merge-without-netlogond
Diffstat (limited to 'source3/smbd/notify.c')
-rw-r--r--source3/smbd/notify.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/source3/smbd/notify.c b/source3/smbd/notify.c
index d141fb2180..12a75cc9f6 100644
--- a/source3/smbd/notify.c
+++ b/source3/smbd/notify.c
@@ -339,6 +339,9 @@ void notify_fname(connection_struct *conn, uint32 action, uint32 filter,
const char *path)
{
char *fullpath;
+ char *parent;
+ const char *name;
+ SMB_STRUCT_STAT sbuf;
if (path[0] == '.' && path[1] == '/') {
path += 2;
@@ -348,6 +351,13 @@ void notify_fname(connection_struct *conn, uint32 action, uint32 filter,
return;
}
+ if (parent_dirname(talloc_tos(), path, &parent, &name)
+ && (SMB_VFS_STAT(conn, parent, &sbuf) != -1)) {
+ notify_onelevel(conn->notify_ctx, action, filter,
+ SMB_VFS_FILE_ID_CREATE(conn, &sbuf),
+ name);
+ }
+
notify_trigger(conn->notify_ctx, action, filter, fullpath);
SAFE_FREE(fullpath);
}