diff options
author | in2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-12-04 18:42:53 +0800 |
---|---|---|
committer | in2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-12-04 18:42:53 +0800 |
commit | ae2aa394c8861cd7823fa9c436892491afb6411e (patch) | |
tree | f48a1e7ae48eb8eb009ce5f74fef344283b9f7fc | |
parent | 9ea952adeca21cf674d7ba96ad3a9ddf19b50d12 (diff) | |
download | pttbbs-ae2aa394c8861cd7823fa9c436892491afb6411e.tar pttbbs-ae2aa394c8861cd7823fa9c436892491afb6411e.tar.gz pttbbs-ae2aa394c8861cd7823fa9c436892491afb6411e.tar.bz2 pttbbs-ae2aa394c8861cd7823fa9c436892491afb6411e.tar.lz pttbbs-ae2aa394c8861cd7823fa9c436892491afb6411e.tar.xz pttbbs-ae2aa394c8861cd7823fa9c436892491afb6411e.tar.zst pttbbs-ae2aa394c8861cd7823fa9c436892491afb6411e.zip |
use rfork()
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@1394 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r-- | mbbsd/mbbsd.c | 4 | ||||
-rw-r--r-- | sample/pttbbs.conf | 3 |
2 files changed, 7 insertions, 0 deletions
diff --git a/mbbsd/mbbsd.c b/mbbsd/mbbsd.c index 42bb48a2..028a91b6 100644 --- a/mbbsd/mbbsd.c +++ b/mbbsd/mbbsd.c @@ -19,6 +19,10 @@ static int use_shell_login_mode = 0; static struct sockaddr_in xsin; +#ifdef USE_RFORK +#define fork() rfork(RFFDG | RFPROC | RFNOWAIT) +#endif + /* set signal handler, which won't be reset once signal comes */ static void signal_restart(int signum, void (*handler) (int)) diff --git a/sample/pttbbs.conf b/sample/pttbbs.conf index 20b6b30b..ff006f90 100644 --- a/sample/pttbbs.conf +++ b/sample/pttbbs.conf @@ -116,6 +116,9 @@ /* 若定義, 在使用者註冊之前, 會先顯示出該檔案, 經使用者確認後才能註冊 */ //#define HAVE_USERAGREEMENT "etc/UserAgreement" +/* 使用 rfork()取代 fork() . 目前只在 FreeBSD上有效 */ +//#define USE_RFORK + /* 前進站畫面 */ #define INSCREEN \ "前進站畫面 (請至 pttbbs.conf 修改您的前進站畫面)" |