From bb81e23e176ec7dfe0111b5aa2946a51239ef3b9 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Sun, 30 Dec 2001 01:46:38 +0000 Subject: When running interactive we want to set our own process group for signal management. Jeremy. (This used to be commit fffae94dd5699f44c0b1c8081587deafd89b3fc0) --- source3/nmbd/nmbd.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'source3/nmbd/nmbd.c') diff --git a/source3/nmbd/nmbd.c b/source3/nmbd/nmbd.c index 29b6c0347a..b2ff81675a 100644 --- a/source3/nmbd/nmbd.c +++ b/source3/nmbd/nmbd.c @@ -803,6 +803,15 @@ static void usage(char *pname) become_daemon(); } +#if HAVE_SETPGID + /* + * If we're interactive we want to set our own process group for + * signal management. + */ + if (opt_interactive) + setpgid( (pid_t)0, (pid_t)0 ); +#endif + #ifndef SYNC_DNS /* Setup the async dns. We do it here so it doesn't have all the other stuff initialised and thus chewing memory and sockets */ -- cgit