From: Love Hörnquist-Åstrand Date: Sat, 19 Jan 2002 16:31:25 +0000 (+0000) Subject: bosserver-nofork-20020119 X-Git-Tag: openafs-devel-1_3_0~50 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=b05cae13822beda473158c3bd7a8bc250c4acf71;p=packages%2Fo%2Fopenafs.git bosserver-nofork-20020119 Make it easier to debug bosserver by adding a -nofork flag for the !nt40 env's. --- diff --git a/src/bozo/bosserver.c b/src/bozo/bosserver.c index 59a1a1931..28bffe44a 100644 --- a/src/bozo/bosserver.c +++ b/src/bozo/bosserver.c @@ -670,7 +670,9 @@ char **envp; struct ktc_encryptionKey tkey; int i; char namebuf[AFSDIR_PATH_MAX]; - +#ifndef AFS_NT40_ENV + int nofork = 0; +#endif #ifdef AFS_AIX32_ENV struct sigaction nsa; @@ -748,6 +750,9 @@ char **envp; DoSyslog = 1; DoSyslogFacility = atoi(argv[code]+8); } + else if (strcmp(argv[code], "-nofork")==0) { + nofork = 1; + } #endif else if (strcmp(argv[code], "-enable_peer_stats")==0) { rx_enablePeerRPCStats(); @@ -768,6 +773,7 @@ char **envp; printf("Usage: bosserver [-noauth] [-log] " "[-syslog[=FACILITY]] " "[-enable_peer_stats] [-enable_process_stats] " + "[-nofork] " "[-help]\n"); #else printf("Usage: bosserver [-noauth] [-log] " @@ -811,6 +817,7 @@ char **envp; /* go into the background and remove our controlling tty */ #ifndef AFS_NT40_ENV + if (!nofork) background(); #endif /* ! AFS_NT40_ENV */