diff options
Diffstat (limited to 'source3/rpc_server/lsasd.c')
-rw-r--r-- | source3/rpc_server/lsasd.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/source3/rpc_server/lsasd.c b/source3/rpc_server/lsasd.c index fd6c248294..a1ac49a47a 100644 --- a/source3/rpc_server/lsasd.c +++ b/source3/rpc_server/lsasd.c @@ -261,7 +261,8 @@ static bool lsasd_child_init(struct tevent_context *ev_ctx, return false; } - if (!serverid_register(procid_self(), FLAG_MSG_GENERAL)) { + if (!serverid_register(messaging_server_id(msg_ctx), + FLAG_MSG_GENERAL)) { return false; } @@ -878,9 +879,6 @@ void start_lsasd(struct tevent_context *ev_ctx, return; } - /* save the parent process id so the children can use it later */ - parent_id = procid_self(); - status = reinit_after_fork(msg_ctx, ev_ctx, true); @@ -889,6 +887,9 @@ void start_lsasd(struct tevent_context *ev_ctx, smb_panic("reinit_after_fork() failed"); } + /* save the parent process id so the children can use it later */ + parent_id = messaging_server_id(msg_ctx); + lsasd_reopen_logs(0); pfh_daemon_config(DAEMON_NAME, &pf_lsasd_cfg, @@ -920,7 +921,8 @@ void start_lsasd(struct tevent_context *ev_ctx, exit(1); } - if (!serverid_register(procid_self(), FLAG_MSG_GENERAL)) { + if (!serverid_register(messaging_server_id(msg_ctx), + FLAG_MSG_GENERAL)) { exit(1); } |