diff options
-rw-r--r-- | source4/ldap_server/ldap_server.c | 4 | ||||
-rw-r--r-- | source4/ldap_server/ldap_server.h | 1 | ||||
-rw-r--r-- | source4/lib/events/events.c | 3 | ||||
-rw-r--r-- | source4/libcli/raw/clisocket.c | 2 | ||||
-rw-r--r-- | source4/libcli/raw/rawacl.c | 5 | ||||
-rw-r--r-- | source4/libcli/raw/rawnegotiate.c | 4 | ||||
-rw-r--r-- | source4/libnet/libnet_become_dc.c | 6 | ||||
-rw-r--r-- | source4/libnet/libnet_vampire.c | 2 | ||||
-rw-r--r-- | source4/wrepl_server/wrepl_in_connection.c | 4 |
9 files changed, 15 insertions, 16 deletions
diff --git a/source4/ldap_server/ldap_server.c b/source4/ldap_server/ldap_server.c index 9bb1279a99..c7b1099166 100644 --- a/source4/ldap_server/ldap_server.c +++ b/source4/ldap_server/ldap_server.c @@ -345,7 +345,7 @@ static void ldapsrv_accept(struct stream_connection *c) conn->connection = c; conn->service = ldapsrv_service; conn->sockets.raw = c->socket; - conn->lp_ctx = global_loadparm; + conn->lp_ctx = ldapsrv_service->task->lp_ctx; c->private = conn; @@ -523,6 +523,8 @@ static void ldapsrv_task_init(struct task_server *task) ldap_service = talloc_zero(task, struct ldapsrv_service); if (ldap_service == NULL) goto failed; + ldap_service->task = task; + ldap_service->tls_params = tls_initialise(ldap_service, task->lp_ctx); if (ldap_service->tls_params == NULL) goto failed; diff --git a/source4/ldap_server/ldap_server.h b/source4/ldap_server/ldap_server.h index 88af0fb5fc..4f7a5b9be9 100644 --- a/source4/ldap_server/ldap_server.h +++ b/source4/ldap_server/ldap_server.h @@ -65,6 +65,7 @@ struct ldapsrv_call { struct ldapsrv_service { struct tls_params *tls_params; + struct task_server *task; }; #include "ldap_server/proto.h" diff --git a/source4/lib/events/events.c b/source4/lib/events/events.c index 245be14326..555a5092cc 100644 --- a/source4/lib/events/events.c +++ b/source4/lib/events/events.c @@ -103,11 +103,8 @@ static void event_backend_init(void) { #if _SAMBA_BUILD_ init_module_fn static_init[] = { STATIC_LIBEVENTS_MODULES }; - init_module_fn *shared_init; if (event_backends) return; - shared_init = load_samba_modules(NULL, global_loadparm, "events"); run_init_functions(static_init); - run_init_functions(shared_init); #else bool events_standard_init(void); bool events_select_init(void); diff --git a/source4/libcli/raw/clisocket.c b/source4/libcli/raw/clisocket.c index 8beaef3daa..8fcb8bb48c 100644 --- a/source4/libcli/raw/clisocket.c +++ b/source4/libcli/raw/clisocket.c @@ -83,7 +83,7 @@ struct composite_context *smbcli_sock_connect_send(TALLOC_CTX *mem_ctx, ctx = socket_connect_multi_send(state, host_addr, state->num_ports, state->ports, - lp_resolve_context(global_loadparm), + resolve_ctx, state->ctx->event_ctx); if (ctx == NULL) goto failed; ctx->async.fn = smbcli_sock_connect_recv_conn; diff --git a/source4/libcli/raw/rawacl.c b/source4/libcli/raw/rawacl.c index 9d2068f35f..847d133173 100644 --- a/source4/libcli/raw/rawacl.c +++ b/source4/libcli/raw/rawacl.c @@ -77,8 +77,7 @@ NTSTATUS smb_raw_query_secdesc_recv(struct smbcli_request *req, nt.out.data.length = IVAL(nt.out.params.data, 0); - ndr = ndr_pull_init_blob(&nt.out.data, mem_ctx, - lp_iconv_convenience(global_loadparm)); + ndr = ndr_pull_init_blob(&nt.out.data, mem_ctx, NULL); if (!ndr) { return NT_STATUS_INVALID_PARAMETER; } @@ -136,7 +135,7 @@ struct smbcli_request *smb_raw_set_secdesc_send(struct smbcli_tree *tree, nt.in.params.data = params; nt.in.params.length = 8; - ndr = ndr_push_init_ctx(NULL, lp_iconv_convenience(global_loadparm)); + ndr = ndr_push_init_ctx(NULL, NULL); if (!ndr) return NULL; ndr_err = ndr_push_security_descriptor(ndr, NDR_SCALARS|NDR_BUFFERS, io->set_secdesc.in.sd); diff --git a/source4/libcli/raw/rawnegotiate.c b/source4/libcli/raw/rawnegotiate.c index 78b9082521..fc7725cc55 100644 --- a/source4/libcli/raw/rawnegotiate.c +++ b/source4/libcli/raw/rawnegotiate.c @@ -175,11 +175,11 @@ NTSTATUS smb_raw_negotiate_recv(struct smbcli_request *req) } /* a way to force ascii SMB */ - if (!lp_unicode(global_loadparm)) { + if (!transport->options.unicode) { transport->negotiate.capabilities &= ~CAP_UNICODE; } - if (!lp_nt_status_support(global_loadparm)) { + if (!transport->options.ntstatus_support) { transport->negotiate.capabilities &= ~CAP_STATUS32; } diff --git a/source4/libnet/libnet_become_dc.c b/source4/libnet/libnet_become_dc.c index e51a2feadf..862631ffa9 100644 --- a/source4/libnet/libnet_become_dc.c +++ b/source4/libnet/libnet_become_dc.c @@ -2017,7 +2017,7 @@ static void becomeDC_drsuapi1_add_entry_send(struct libnet_BecomeDC_state *s) v[0].sid = s->zero_sid; v[0].dn = s->forest.schema_dn_str; - ndr_err = ndr_push_struct_blob(&vd[0], vd, lp_iconv_convenience(global_loadparm), &v[0], + ndr_err = ndr_push_struct_blob(&vd[0], vd, NULL, &v[0], (ndr_push_flags_fn_t)ndr_push_drsuapi_DsReplicaObjectIdentifier3); if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) { c->status = ndr_map_error2ntstatus(ndr_err); @@ -2049,7 +2049,7 @@ static void becomeDC_drsuapi1_add_entry_send(struct libnet_BecomeDC_state *s) v[0].sid = s->zero_sid; v[0].dn = s->domain.dn_str; - ndr_err = ndr_push_struct_blob(&vd[0], vd, lp_iconv_convenience(global_loadparm), &v[0], + ndr_err = ndr_push_struct_blob(&vd[0], vd, NULL, &v[0], (ndr_push_flags_fn_t)ndr_push_drsuapi_DsReplicaObjectIdentifier3); if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) { c->status = ndr_map_error2ntstatus(ndr_err); @@ -2131,7 +2131,7 @@ static void becomeDC_drsuapi1_add_entry_send(struct libnet_BecomeDC_state *s) v[0].sid = s->zero_sid; v[0].dn = s->dest_dsa.computer_dn_str; - ndr_err = ndr_push_struct_blob(&vd[0], vd, lp_iconv_convenience(global_loadparm), &v[0], + ndr_err = ndr_push_struct_blob(&vd[0], vd, NULL, &v[0], (ndr_push_flags_fn_t)ndr_push_drsuapi_DsReplicaObjectIdentifier3); if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) { c->status = ndr_map_error2ntstatus(ndr_err); diff --git a/source4/libnet/libnet_vampire.c b/source4/libnet/libnet_vampire.c index c707f82744..0f82d98673 100644 --- a/source4/libnet/libnet_vampire.c +++ b/source4/libnet/libnet_vampire.c @@ -72,7 +72,7 @@ static NTSTATUS fix_user(TALLOC_CTX *mem_ctx, user->user_private_info.SensitiveData = data.data; user->user_private_info.DataLength = data.length; - ndr_err = ndr_pull_struct_blob(&data, mem_ctx, lp_iconv_convenience(global_loadparm), &keys, (ndr_pull_flags_fn_t)ndr_pull_netr_USER_KEYS); + ndr_err = ndr_pull_struct_blob(&data, mem_ctx, NULL, &keys, (ndr_pull_flags_fn_t)ndr_pull_netr_USER_KEYS); if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) { *error_string = talloc_asprintf(mem_ctx, "Failed to parse Sensitive Data for %s:", username); dump_data(10, data.data, data.length); diff --git a/source4/wrepl_server/wrepl_in_connection.c b/source4/wrepl_server/wrepl_in_connection.c index f2cf7c6113..721a005213 100644 --- a/source4/wrepl_server/wrepl_in_connection.c +++ b/source4/wrepl_server/wrepl_in_connection.c @@ -66,7 +66,7 @@ static NTSTATUS wreplsrv_recv_request(void *private, DATA_BLOB blob) packet_in_blob.length = blob.length - 4; ndr_err = ndr_pull_struct_blob(&packet_in_blob, call, - lp_iconv_convenience(global_loadparm), + lp_iconv_convenience(wreplconn->service->task->lp_ctx), &call->req_packet, (ndr_pull_flags_fn_t)ndr_pull_wrepl_packet); if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) { @@ -91,7 +91,7 @@ static NTSTATUS wreplsrv_recv_request(void *private, DATA_BLOB blob) /* and now encode the reply */ packet_out_wrap.packet = call->rep_packet; ndr_err = ndr_push_struct_blob(&packet_out_blob, call, - lp_iconv_convenience(global_loadparm), + lp_iconv_convenience(wreplconn->service->task->lp_ctx), &packet_out_wrap, (ndr_push_flags_fn_t)ndr_push_wrepl_wrap); if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) { |