From ef7f4a142068757dcf0dc11c5b7cf03755be45a8 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Mon, 15 Nov 2010 10:12:22 +1100 Subject: s4-server: make server sockets a child of the task context We previously allocated sockets as direct children of the event context. That led to crashes if a service called task_server_terminate(), as it left the socket open and handling events for a dead protocol. Making them a child of the task allows the task to terminate and take all its sockets with it. Pair-Programmed-With: Andrew Bartlett --- source4/torture/rpc/spoolss_notify.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source4/torture') diff --git a/source4/torture/rpc/spoolss_notify.c b/source4/torture/rpc/spoolss_notify.c index facfd3e52a..a613e31a9e 100644 --- a/source4/torture/rpc/spoolss_notify.c +++ b/source4/torture/rpc/spoolss_notify.c @@ -464,7 +464,7 @@ static bool test_start_dcerpc_server(struct torture_context *tctx, torture_assert_ntstatus_ok(tctx, status, "unable to initialize process models"); - status = smbsrv_add_socket(event_ctx, tctx->lp_ctx, process_model_startup("single"), address); + status = smbsrv_add_socket(tctx, event_ctx, tctx->lp_ctx, process_model_startup("single"), address); torture_assert_ntstatus_ok(tctx, status, "starting smb server"); status = dcesrv_init_context(tctx, tctx->lp_ctx, endpoints, &dce_ctx); -- cgit