summaryrefslogtreecommitdiffstats
path: root/usr.bin/rpcgen
diff options
context:
space:
mode:
authored <ed@FreeBSD.org>2012-10-19 14:49:42 +0000
committered <ed@FreeBSD.org>2012-10-19 14:49:42 +0000
commitaf31e8843c2cc0ba388a33f341de8da1b50de433 (patch)
treeddffe542a2e921ec48c73d322a2046f559a9d74f /usr.bin/rpcgen
parentb1462253851ab8c1f6dde48bb7796b15d3f38253 (diff)
downloadFreeBSD-src-af31e8843c2cc0ba388a33f341de8da1b50de433.zip
FreeBSD-src-af31e8843c2cc0ba388a33f341de8da1b50de433.tar.gz
More -Wmissing-variable-declarations fixes.
In addition to adding `static' where possible: - bin/date: Move `retval' into extern.h to make it visible to date.c. - bin/ed: Move globally used variables into ed.h. - sbin/camcontrol: Move `verbose' into camcontrol.h and fix shadow warnings. - usr.bin/calendar: Remove unneeded variables. - usr.bin/chat: Make `line' local instead of global. - usr.bin/elfdump: Comment out unneeded function. - usr.bin/rlogin: Use _Noreturn instead of __dead2. - usr.bin/tset: Pull `Ospeed' into extern.h. - usr.sbin/mfiutil: Put global variables in mfiutil.h. - usr.sbin/pkg: Remove unused `os_corres'. - usr.sbin/quotaon, usr.sbin/repquota: Remove unused `qfname'.
Diffstat (limited to 'usr.bin/rpcgen')
-rw-r--r--usr.bin/rpcgen/rpc_main.c2
-rw-r--r--usr.bin/rpcgen/rpc_svcout.c2
-rw-r--r--usr.bin/rpcgen/rpc_util.c4
3 files changed, 4 insertions, 4 deletions
diff --git a/usr.bin/rpcgen/rpc_main.c b/usr.bin/rpcgen/rpc_main.c
index a54c3e9..3755f4c 100644
--- a/usr.bin/rpcgen/rpc_main.c
+++ b/usr.bin/rpcgen/rpc_main.c
@@ -435,7 +435,7 @@ c_initialize(void)
}
-const char rpcgen_table_dcl[] = "struct rpcgen_table {\n\
+static const char rpcgen_table_dcl[] = "struct rpcgen_table {\n\
char *(*proc)(); \n\
xdrproc_t xdr_arg; \n\
unsigned len_arg; \n\
diff --git a/usr.bin/rpcgen/rpc_svcout.c b/usr.bin/rpcgen/rpc_svcout.c
index 08cf94c..4b951a3 100644
--- a/usr.bin/rpcgen/rpc_svcout.c
+++ b/usr.bin/rpcgen/rpc_svcout.c
@@ -54,7 +54,7 @@ static char RESULT[] = "result";
static char ROUTINE[] = "local";
static char RETVAL[] = "retval";
-char _errbuf[256]; /* For all messages */
+static char _errbuf[256]; /* For all messages */
void internal_proctype( proc_list * );
static void write_real_program( definition * );
diff --git a/usr.bin/rpcgen/rpc_util.c b/usr.bin/rpcgen/rpc_util.c
index 9d1c85b..bf0ca5d 100644
--- a/usr.bin/rpcgen/rpc_util.c
+++ b/usr.bin/rpcgen/rpc_util.c
@@ -59,8 +59,8 @@ int linenum = 0; /* current line number */
const char *infilename; /* input filename */
#define NFILES 7
-const char *outfiles[NFILES]; /* output file names */
-int nfiles;
+static const char *outfiles[NFILES]; /* output file names */
+static int nfiles;
FILE *fout; /* file pointer of current output */
FILE *fin; /* file pointer of current input */
OpenPOWER on IntegriCloud