mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
When running interactive we want to set our own process group for
signal management. Jeremy.
This commit is contained in:
parent
54cbfc7ebc
commit
fffae94dd5
4
source/configure
vendored
4
source/configure
vendored
@ -945,7 +945,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
|
||||
|
||||
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
|
||||
|
||||
for ac_prog in mawk gawk nawk awk
|
||||
for ac_prog in gawk mawk nawk awk
|
||||
do
|
||||
# Extract the first word of "$ac_prog", so it can be a program name with args.
|
||||
set dummy $ac_prog; ac_word=$2
|
||||
@ -5191,7 +5191,7 @@ else
|
||||
fi
|
||||
done
|
||||
|
||||
for ac_func in fstat strchr utime utimes getrlimit fsync bzero memset strlcpy strlcat
|
||||
for ac_func in fstat strchr utime utimes getrlimit fsync bzero memset strlcpy strlcat setpgid
|
||||
do
|
||||
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
|
||||
echo "configure:5198: checking for $ac_func" >&5
|
||||
|
@ -554,7 +554,7 @@ else
|
||||
fi
|
||||
|
||||
AC_CHECK_FUNCS(waitpid getcwd strdup strtoul strerror chown fchown chmod fchmod chroot)
|
||||
AC_CHECK_FUNCS(fstat strchr utime utimes getrlimit fsync bzero memset strlcpy strlcat)
|
||||
AC_CHECK_FUNCS(fstat strchr utime utimes getrlimit fsync bzero memset strlcpy strlcat setpgid)
|
||||
AC_CHECK_FUNCS(memmove vsnprintf snprintf asprintf vasprintf setsid glob strpbrk pipe crypt16 getauthuid)
|
||||
AC_CHECK_FUNCS(strftime sigprocmask sigblock sigaction sigset innetgr setnetgrent getnetgrent endnetgrent)
|
||||
AC_CHECK_FUNCS(initgroups select poll rdchk getgrnam getgrent pathconf)
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* include/config.h.in. Generated automatically from configure.in by autoheader 2.13. */
|
||||
/* include/config.h.in. Generated automatically from configure.in by autoheader. */
|
||||
|
||||
/* Define if on AIX 3.
|
||||
System headers sometimes define this.
|
||||
@ -695,6 +695,9 @@
|
||||
/* Define if you have the setnetgrent function. */
|
||||
#undef HAVE_SETNETGRENT
|
||||
|
||||
/* Define if you have the setpgid function. */
|
||||
#undef HAVE_SETPGID
|
||||
|
||||
/* Define if you have the setpriv function. */
|
||||
#undef HAVE_SETPRIV
|
||||
|
||||
|
@ -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 */
|
||||
|
@ -822,6 +822,15 @@ int main(int argc, char **argv)
|
||||
if (!interactive)
|
||||
become_daemon();
|
||||
|
||||
#if HAVE_SETPGID
|
||||
/*
|
||||
* If we're interactive we want to set our own process group for
|
||||
* signal management.
|
||||
*/
|
||||
if (interactive)
|
||||
setpgid( (pid_t)0, (pid_t)0);
|
||||
#endif
|
||||
|
||||
load_interfaces();
|
||||
|
||||
secrets_init();
|
||||
|
@ -785,6 +785,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 (interactive)
|
||||
setpgid( (pid_t)0, (pid_t)0);
|
||||
#endif
|
||||
|
||||
if (!directory_exist(lp_lockdir(), NULL)) {
|
||||
mkdir(lp_lockdir(), 0755);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user