summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1992-11-01 06:50:15 +0000
committerJim Meyering <jim@meyering.net>1992-11-01 06:50:15 +0000
commitcf5cedb71a8ee923d78d3f66e52ecddbf7a8d994 (patch)
treef17fae9aa7c21eeab8cec5cacb1464152c08bd98 /src
parentccbd1d7dc5189f4637468a8136f672e60ee0e531 (diff)
downloadcoreutils-cf5cedb71a8ee923d78d3f66e52ecddbf7a8d994.tar.xz
Make file-scope variable static.
Diffstat (limited to 'src')
-rw-r--r--src/env.c2
-rw-r--r--src/expr.c2
-rw-r--r--src/id.c18
-rw-r--r--src/nice.c2
-rw-r--r--src/pathchk.c2
-rw-r--r--src/printf.c2
-rw-r--r--src/stty.c2
-rw-r--r--src/who.c10
8 files changed, 20 insertions, 20 deletions
diff --git a/src/env.c b/src/env.c
index b322dee60..a9bc501df 100644
--- a/src/env.c
+++ b/src/env.c
@@ -91,7 +91,7 @@ extern char **environ;
/* The name by which this program was run. */
char *program_name;
-struct option longopts[] =
+static struct option longopts[] =
{
{"ignore-environment", 0, NULL, 'i'},
{"unset", 1, NULL, 'u'},
diff --git a/src/expr.c b/src/expr.c
index db9586922..61a6c091d 100644
--- a/src/expr.c
+++ b/src/expr.c
@@ -62,7 +62,7 @@ struct valinfo
typedef struct valinfo VALUE;
/* The arguments given to the program, minus the program name. */
-char **args;
+static char **args;
/* The name this program was run with. */
char *program_name;
diff --git a/src/id.c b/src/id.c
index beddc1356..1c9482fc6 100644
--- a/src/id.c
+++ b/src/id.c
@@ -68,28 +68,28 @@ void usage ();
char *program_name;
/* If nonzero, output only the group ID(s). -g */
-int just_group = 0;
+static int just_group = 0;
/* If nonzero, output user/group name instead of ID number. -n */
-int use_name = 0;
+static int use_name = 0;
/* If nonzero, output real UID/GID instead of default effective UID/GID. -r */
-int use_real = 0;
+static int use_real = 0;
/* If nonzero, output only the user ID(s). -u */
-int just_user = 0;
+static int just_user = 0;
/* If nonzero, output only the supplementary groups. -G */
-int just_group_list = 0;
+static int just_group_list = 0;
/* The real and effective IDs of the user to print. */
-uid_t ruid, euid;
-gid_t rgid, egid;
+static uid_t ruid, euid;
+static gid_t rgid, egid;
/* The number of errors encountered so far. */
-int problems = 0;
+static int problems = 0;
-struct option longopts[] =
+static struct option longopts[] =
{
{"group", 0, NULL, 'g'},
{"name", 0, NULL, 'n'},
diff --git a/src/nice.c b/src/nice.c
index 4911fcc70..6878a3422 100644
--- a/src/nice.c
+++ b/src/nice.c
@@ -33,7 +33,7 @@ void usage ();
/* The name this program was run with. */
char *program_name;
-struct option longopts[] =
+static struct option longopts[] =
{
{"adjustment", 1, NULL, 'n'},
{NULL, 0, NULL, 0}
diff --git a/src/pathchk.c b/src/pathchk.c
index a8db2b28f..0753ada70 100644
--- a/src/pathchk.c
+++ b/src/pathchk.c
@@ -136,7 +136,7 @@ main (argc, argv)
/* Each element is nonzero if the corresponding ASCII character is
in the POSIX portable character set, and zero if it is not.
In addition, the entry for `/' is nonzero to simplify checking. */
-char portable_chars[] =
+static char portable_chars[] =
{
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0-15 */
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 16-31 */
diff --git a/src/printf.c b/src/printf.c
index b546ef65b..99f5f6b9a 100644
--- a/src/printf.c
+++ b/src/printf.c
@@ -74,7 +74,7 @@ void verify ();
char *program_name;
/* The value to return to the calling program. */
-int exit_status;
+static int exit_status;
void
main (argc, argv)
diff --git a/src/stty.c b/src/stty.c
index 5349af0f2..8810762cd 100644
--- a/src/stty.c
+++ b/src/stty.c
@@ -160,7 +160,7 @@ struct mode_info
unsigned long mask; /* Other bits to turn off for this mode. */
};
-struct mode_info mode_info[] =
+static struct mode_info mode_info[] =
{
{"parenb", control, REV, PARENB, 0},
{"parodd", control, REV, PARODD, 0},
diff --git a/src/who.c b/src/who.c
index d5f40dc55..0612b6d6b 100644
--- a/src/who.c
+++ b/src/who.c
@@ -76,21 +76,21 @@ char *program_name;
/* If nonzero, display only a list of usernames and count of
the users logged on.
Ignored for `who am i'. */
-int short_list;
+static int short_list;
/* If nonzero, display the hours:minutes since each user has touched
the keyboard, or "." if within the last minute, or "old" if
not within the last day. */
-int include_idle;
+static int include_idle;
/* If nonzero, display a line at the top describing each field. */
-int include_heading;
+static int include_heading;
/* If nonzero, display a `+' for each user if mesg y, a `-' if mesg n,
or a `?' if their tty cannot be statted. */
-int include_mesg;
+static int include_mesg;
-struct option longopts[] =
+static struct option longopts[] =
{
{"count", 0, NULL, 'q'},
{"idle", 0, NULL, 'u'},