summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/nmbd/asyncdns.c5
-rw-r--r--source3/nmbd/nmbd.c5
2 files changed, 10 insertions, 0 deletions
diff --git a/source3/nmbd/asyncdns.c b/source3/nmbd/asyncdns.c
index 5e5565991e..0329491c4a 100644
--- a/source3/nmbd/asyncdns.c
+++ b/source3/nmbd/asyncdns.c
@@ -164,6 +164,11 @@ void start_async_dns(void)
CatchSignal(SIGHUP, SIG_IGN);
CatchSignal(SIGTERM, SIGNAL_CAST sig_term );
+ if (!reinit_after_fork(nmbd_messaging_context())) {
+ DEBUG(0,("reinit_after_fork() failed\n"));
+ smb_panic("reinit_after_fork() failed");
+ }
+
asyncdns_process();
}
diff --git a/source3/nmbd/nmbd.c b/source3/nmbd/nmbd.c
index 01fdbbc5a4..e765fcb725 100644
--- a/source3/nmbd/nmbd.c
+++ b/source3/nmbd/nmbd.c
@@ -901,6 +901,11 @@ static bool open_sockets(bool isdaemon, int port)
pidfile_create("nmbd");
+ if (!reinit_after_fork(nmbd_messaging_context())) {
+ DEBUG(0,("reinit_after_fork() failed\n"));
+ exit(1);
+ }
+
/* get broadcast messages */
claim_connection(NULL,"",FLAG_MSG_GENERAL|FLAG_MSG_DBWRAP);