From c38c2765d1059b33f044a42c6555f3d10d339911 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Thu, 21 Feb 2008 17:17:37 +0100 Subject: Remove yet more uses of global_loadparm. (This used to be commit e01c1e87c0fe9709df7eb5b863f7ce85564174cd) --- source4/ntvfs/sysdep/inotify.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'source4/ntvfs/sysdep/inotify.c') diff --git a/source4/ntvfs/sysdep/inotify.c b/source4/ntvfs/sysdep/inotify.c index 3fa710415b..093c15abab 100644 --- a/source4/ntvfs/sysdep/inotify.c +++ b/source4/ntvfs/sysdep/inotify.c @@ -244,11 +244,6 @@ static void inotify_handler(struct event_context *ev, struct fd_event *fde, static NTSTATUS inotify_setup(struct sys_notify_context *ctx) { struct inotify_private *in; - - if (!lp_parm_bool(global_loadparm, NULL, "notify", "inotify", true)) { - return NT_STATUS_INVALID_SYSTEM_SERVICE; - } - in = talloc(ctx, struct inotify_private); NT_STATUS_HAVE_NO_MEMORY(in); in->fd = inotify_init(); @@ -339,6 +334,10 @@ static NTSTATUS inotify_watch(struct sys_notify_context *ctx, /* maybe setup the inotify fd */ if (ctx->private_data == NULL) { NTSTATUS status; + if (!lp_parm_bool(global_loadparm, NULL, "notify", "inotify", true)) { + return NT_STATUS_INVALID_SYSTEM_SERVICE; + } + status = inotify_setup(ctx); NT_STATUS_NOT_OK_RETURN(status); } -- cgit