svn commit: samba r21327 - in branches/SAMBA_3_0_25/source/modules:
.
vlendec at samba.org
vlendec at samba.org
Wed Feb 14 04:47:17 GMT 2007
Author: vlendec
Date: 2007-02-14 04:47:15 +0000 (Wed, 14 Feb 2007)
New Revision: 21327
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=21327
Log:
Jim, thanks for the review! :-)
Now to test this...
Volker
Modified:
branches/SAMBA_3_0_25/source/modules/vfs_default.c
Changeset:
Modified: branches/SAMBA_3_0_25/source/modules/vfs_default.c
===================================================================
--- branches/SAMBA_3_0_25/source/modules/vfs_default.c 2007-02-14 04:19:13 UTC (rev 21326)
+++ branches/SAMBA_3_0_25/source/modules/vfs_default.c 2007-02-14 04:47:15 UTC (rev 21327)
@@ -850,6 +850,33 @@
return result;
}
+static NTSTATUS vfswrap_notify_watch(vfs_handle_struct *vfs_handle,
+ struct sys_notify_context *ctx,
+ struct notify_entry *e,
+ void (*callback)(struct sys_notify_context *ctx,
+ void *private_data,
+ struct notify_event *ev),
+ void *private_data, void *handle)
+{
+ /*
+ * So far inotify is the only supported default notify mechanism. If
+ * another platform like the the BSD's or a proprietary Unix comes
+ * along and wants another default, we can play the same trick we
+ * played with Posix ACLs.
+ *
+ * Until that is the case, hard-code inotify here.
+ */
+#ifdef HAVE_INOTIFY
+ if (lp_kernel_change_notify(ctx->conn->params)) {
+ return inotify_watch(ctx, e, callback, private_data, handle);
+ }
+#endif
+ /*
+ * Do nothing, leave everything to notify_internal.c
+ */
+ return NT_STATUS_OK;
+}
+
static size_t vfswrap_fget_nt_acl(vfs_handle_struct *handle, files_struct *fsp, int fd, uint32 security_info, SEC_DESC **ppdesc)
{
size_t result;
@@ -1231,6 +1258,8 @@
SMB_VFS_LAYER_OPAQUE},
{SMB_VFS_OP(vfswrap_realpath), SMB_VFS_OP_REALPATH,
SMB_VFS_LAYER_OPAQUE},
+ {SMB_VFS_OP(vfswrap_notify_watch), SMB_VFS_OP_NOTIFY_WATCH,
+ SMB_VFS_LAYER_OPAQUE},
/* NT ACL operations. */
More information about the samba-cvs
mailing list