1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-24 21:34:56 +03:00

s3:smbd/server: create smbd_parent_context earlier

metze
This commit is contained in:
Stefan Metzmacher 2011-12-13 08:54:49 +01:00
parent dc38db31ba
commit 1738a61b84

View File

@ -1126,6 +1126,14 @@ extern void build_options(bool screen);
smbd_server_conn->msg_ctx = msg_ctx;
parent = talloc_zero(ev_ctx, struct smbd_parent_context);
if (!parent) {
exit_server("talloc(struct smbd_parent_context) failed");
}
parent->interactive = interactive;
parent->ev_ctx = ev_ctx;
parent->msg_ctx = msg_ctx;
smbd_setup_sig_term_handler();
smbd_setup_sig_hup_handler(ev_ctx,
msg_ctx);
@ -1284,13 +1292,6 @@ extern void build_options(bool screen);
return(0);
}
parent = talloc_zero(ev_ctx, struct smbd_parent_context);
if (!parent) {
exit_server("talloc(struct smbd_parent_context) failed");
}
parent->interactive = interactive;
parent->ev_ctx = ev_ctx;
parent->msg_ctx = msg_ctx;
if (!open_sockets_smbd(parent, ev_ctx, msg_ctx, ports))
exit_server("open_sockets_smbd() failed");