From 49933d6daf80310790b898e8a4dcce3cab88c548 Mon Sep 17 00:00:00 2001 From: kcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> Date: Wed, 20 Oct 2004 03:43:38 +0000 Subject: unsetenv before daemon fork git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2269 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- mbbsd/mbbsd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mbbsd/mbbsd.c b/mbbsd/mbbsd.c index 7ccf5909..ea541e5b 100644 --- a/mbbsd/mbbsd.c +++ b/mbbsd/mbbsd.c @@ -69,6 +69,9 @@ start_daemon() close(fd); } + if(getenv("SSH_CLIENT")) + unsetenv("SSH_CLIENT"); + /* * rocker.011018: we don't need to remember original tty, so request a * new session id @@ -84,9 +87,6 @@ start_daemon() exit(0); } #endif - - if(getenv("SSH_CLIENT")) - unsetenv("SSH_CLIENT"); } static void -- cgit v1.2.3