summaryrefslogtreecommitdiff
path: root/coreutils
diff options
context:
space:
mode:
authorDenis Vlasenko2007-05-17 23:02:14 +0000
committerDenis Vlasenko2007-05-17 23:02:14 +0000
commit5b340830045aa3dc6ca01cd1c6082b09161877d2 (patch)
tree4b2514b790deaafc68d6c9caa8706a2ab94bbc52 /coreutils
parentcd5c7866e328b502d946485ad1886ce26cffabfa (diff)
downloadbusybox-5b340830045aa3dc6ca01cd1c6082b09161877d2.zip
busybox-5b340830045aa3dc6ca01cd1c6082b09161877d2.tar.gz
several *.c files:
move 'extern environ' up to the location of #includes
Diffstat (limited to 'coreutils')
-rw-r--r--coreutils/env.c2
-rw-r--r--coreutils/printenv.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/coreutils/env.c b/coreutils/env.c
index f47d450..2a271f7 100644
--- a/coreutils/env.c
+++ b/coreutils/env.c
@@ -32,6 +32,7 @@
#include "busybox.h"
#include <errno.h>
#include <getopt.h> /* struct option */
+extern char **environ;
#if ENABLE_FEATURE_ENV_LONG_OPTIONS
static const struct option env_long_options[] = {
@@ -49,7 +50,6 @@ int env_main(int argc, char** argv)
char **ep;
unsigned opt;
llist_t *unset_env = NULL;
- extern char **environ;
opt_complementary = "u::";
#if ENABLE_FEATURE_ENV_LONG_OPTIONS
diff --git a/coreutils/printenv.c b/coreutils/printenv.c
index 1d41eeb..935f52d 100644
--- a/coreutils/printenv.c
+++ b/coreutils/printenv.c
@@ -12,11 +12,11 @@
#include <string.h>
#include <stdlib.h>
#include "busybox.h"
+extern char **environ;
int printenv_main(int argc, char **argv);
int printenv_main(int argc, char **argv)
{
- extern char **environ;
int e = 0;
/* no variables specified, show whole env */