aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2001-05-13 00:33:16 +0000
committerEric Andersen <andersen@codepoet.org>2001-05-13 00:33:16 +0000
commit4819c3d477e83b846649220fc96534c9bb93d642 (patch)
tree7f77150cefbe61ee6615634e09bfb35f3f4ec347
parent1f3b9f297e948b70a82b82919d0ef4d4e1b61d7f (diff)
downloadbusybox-w32-4819c3d477e83b846649220fc96534c9bb93d642.tar.gz
busybox-w32-4819c3d477e83b846649220fc96534c9bb93d642.tar.bz2
busybox-w32-4819c3d477e83b846649220fc96534c9bb93d642.zip
Make the locale stuff only do the getpid==1 check if BB_INIT is defined
-rw-r--r--applets/busybox.c6
-rw-r--r--busybox.c6
2 files changed, 10 insertions, 2 deletions
diff --git a/applets/busybox.c b/applets/busybox.c
index 41b6069ed..9cc884854 100644
--- a/applets/busybox.c
+++ b/applets/busybox.c
@@ -82,9 +82,13 @@ int main(int argc, char **argv)
82 } 82 }
83#endif 83#endif
84 84
85#ifdef BB_LOCALE_SUPPORT 85#ifdef BB_LOCALE_SUPPORT
86#ifdef BB_INIT
86 if(getpid()!=1) /* Do not set locale for `init' */ 87 if(getpid()!=1) /* Do not set locale for `init' */
88#endif
89 {
87 setlocale(LC_ALL, ""); 90 setlocale(LC_ALL, "");
91 }
88#endif 92#endif
89 93
90 run_applet_by_name(applet_name, argc, argv); 94 run_applet_by_name(applet_name, argc, argv);
diff --git a/busybox.c b/busybox.c
index 41b6069ed..9cc884854 100644
--- a/busybox.c
+++ b/busybox.c
@@ -82,9 +82,13 @@ int main(int argc, char **argv)
82 } 82 }
83#endif 83#endif
84 84
85#ifdef BB_LOCALE_SUPPORT 85#ifdef BB_LOCALE_SUPPORT
86#ifdef BB_INIT
86 if(getpid()!=1) /* Do not set locale for `init' */ 87 if(getpid()!=1) /* Do not set locale for `init' */
88#endif
89 {
87 setlocale(LC_ALL, ""); 90 setlocale(LC_ALL, "");
91 }
88#endif 92#endif
89 93
90 run_applet_by_name(applet_name, argc, argv); 94 run_applet_by_name(applet_name, argc, argv);