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

s3:smbd: use server_messaging_context() instead of sconn->msg_ctx in exit_server_common()

sconn is not available in the parent anymore.

Thanks to Volker Lendecke <vl@samba.org> for finding this!

metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Thu May 31 18:08:06 CEST 2012 on sn-devel-104
This commit is contained in:
Stefan Metzmacher 2012-05-31 15:28:11 +02:00
parent 2ea963b260
commit 6718747268

View File

@ -87,6 +87,7 @@ static void exit_server_common(enum server_exit_reason how,
bool had_open_conn = false;
struct smbXsrv_connection *conn = global_smbXsrv_connection;
struct smbd_server_connection *sconn = NULL;
struct messaging_context *msg_ctx = server_messaging_context();
if (conn != NULL) {
sconn = conn->sconn;
@ -112,14 +113,14 @@ static void exit_server_common(enum server_exit_reason how,
}
/* 3 second timeout. */
print_notify_send_messages(sconn->msg_ctx, 3);
print_notify_send_messages(msg_ctx, 3);
/* delete our entry in the serverid database. */
if (am_parent) {
/*
* For children the parent takes care of cleaning up
*/
serverid_deregister(messaging_server_id(sconn->msg_ctx));
serverid_deregister(messaging_server_id(msg_ctx));
}
#ifdef WITH_DFS