From b8d1a4cd5f686ee95f6cf13634cba1f96e382f26 Mon Sep 17 00:00:00 2001 From: Denis Vlasenko Date: Sat, 20 Sep 2008 16:28:59 +0000 Subject: init: set stderr to NONBLOCK *: s/setenv(a,b,1)/xsetenv(a,b)/ function old new delta init_main 856 895 +39 message 146 144 -2 crond_main 1418 1416 -2 run 661 658 -3 zcip_main 1409 1403 -6 edit_file 910 901 -9 environment 20 - -20 --- miscutils/crond.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'miscutils/crond.c') diff --git a/miscutils/crond.c b/miscutils/crond.c index 2f0bf6ea8..7d1908c63 100644 --- a/miscutils/crond.c +++ b/miscutils/crond.c @@ -187,7 +187,7 @@ int crond_main(int argc UNUSED_PARAM, char **argv) xchdir(CDir); //signal(SIGHUP, SIG_IGN); /* ? original crond dies on HUP... */ - setenv("SHELL", DEFAULT_SHELL, 1); /* once, for all future children */ + xsetenv("SHELL", DEFAULT_SHELL); /* once, for all future children */ crondlog(LVL9 "crond (busybox "BB_VER") started, log level %d", LogLevel); SynchronizeDir(); @@ -275,8 +275,8 @@ static void SetEnv(struct passwd *pas) /* if we want to set user's shell instead: */ /*safe_setenv(env_var_user, "SHELL", pas->pw_shell, 5);*/ #else - setenv("USER", pas->pw_name, 1); - setenv("HOME", pas->pw_dir, 1); + xsetenv("USER", pas->pw_name); + xsetenv("HOME", pas->pw_dir); #endif /* currently, we use constant one: */ /*setenv("SHELL", DEFAULT_SHELL, 1); - done earlier */ -- cgit v1.2.3