From e5895c3c37885c3538666bf6cde75881156419cf Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Fri, 21 Nov 2014 15:53:53 +0100 Subject: [PATCH] param: Make "change notify" global With a central notifyd, we can't do this per share anymore. Notifyd will only look at absolute paths, not shares. Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison --- docs-xml/smbdotconf/misc/changenotify.xml | 3 +-- lib/param/param_table.c | 4 ++-- source3/param/loadparm.c | 3 ++- source3/smbd/service.c | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docs-xml/smbdotconf/misc/changenotify.xml b/docs-xml/smbdotconf/misc/changenotify.xml index 1344dce71b2..70793d68a4c 100644 --- a/docs-xml/smbdotconf/misc/changenotify.xml +++ b/docs-xml/smbdotconf/misc/changenotify.xml @@ -1,7 +1,6 @@ This parameter specifies whether Samba should reply diff --git a/lib/param/param_table.c b/lib/param/param_table.c index 148f79c6df4..9a5881fb82b 100644 --- a/lib/param/param_table.c +++ b/lib/param/param_table.c @@ -1660,8 +1660,8 @@ struct parm_struct parm_table[] = { { .label = "change notify", .type = P_BOOL, - .p_class = P_LOCAL, - .offset = LOCAL_VAR(change_notify), + .p_class = P_GLOBAL, + .offset = GLOBAL_VAR(change_notify), .special = NULL, .enum_list = NULL, }, diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c index af74d68fee5..4228b390ea3 100644 --- a/source3/param/loadparm.c +++ b/source3/param/loadparm.c @@ -239,7 +239,6 @@ static struct loadparm_service sDefault = .acl_map_full_control = true, .acl_group_control = false, .acl_allow_execute_always = false, - .change_notify = true, .kernel_change_notify = true, .allocation_roundup_size = SMB_ROUNDUP_ALLOCATION_SIZE, .aio_read_size = 0, @@ -722,6 +721,8 @@ static void init_globals(struct loadparm_context *lp_ctx, bool reinit_globals) a large number of sites (tridge) */ Globals.hostname_lookups = false; + Globals.change_notify = true, + string_set(Globals.ctx, &Globals.passdb_backend, "tdbsam"); string_set(Globals.ctx, &Globals.ldap_suffix, ""); string_set(Globals.ctx, &Globals.szLdapMachineSuffix, ""); diff --git a/source3/smbd/service.c b/source3/smbd/service.c index d1148e1bc40..05449672fb7 100644 --- a/source3/smbd/service.c +++ b/source3/smbd/service.c @@ -678,7 +678,7 @@ static NTSTATUS make_connection_snum(struct smbXsrv_connection *xconn, on_err_call_dis_hook = true; if ((!conn->printer) && (!conn->ipc) && - lp_change_notify(conn->params)) { + lp_change_notify()) { if (sconn->notify_ctx == NULL) { sconn->notify_ctx = notify_init( sconn, sconn->msg_ctx, sconn->ev_ctx); -- 2.11.4.GIT