summaryrefslogtreecommitdiffstats
path: root/usr.bin/nfsstat
diff options
context:
space:
mode:
authordelphij <delphij@FreeBSD.org>2009-06-23 23:18:19 +0000
committerdelphij <delphij@FreeBSD.org>2009-06-23 23:18:19 +0000
commit1a0c54bf1036d3551790b371822711d08e8abd07 (patch)
treec554fcb2cb7e90cedf6b9891d81510dadfcfb8f9 /usr.bin/nfsstat
parent1cc010a75546cbb8d3bb8b33991884b965b9820f (diff)
downloadFreeBSD-src-1a0c54bf1036d3551790b371822711d08e8abd07.zip
FreeBSD-src-1a0c54bf1036d3551790b371822711d08e8abd07.tar.gz
Use C99 initialization when necessary; apply static to internal rountines.
This makes nfsstat WARNS=3 clean.
Diffstat (limited to 'usr.bin/nfsstat')
-rw-r--r--usr.bin/nfsstat/nfsstat.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/usr.bin/nfsstat/nfsstat.c b/usr.bin/nfsstat/nfsstat.c
index c39e499..b089125 100644
--- a/usr.bin/nfsstat/nfsstat.c
+++ b/usr.bin/nfsstat/nfsstat.c
@@ -35,7 +35,7 @@
*/
#ifndef lint
-static char copyright[] =
+static const char copyright[] =
"@(#) Copyright (c) 1983, 1989, 1993\n\
The Regents of the University of California. All rights reserved.\n";
#endif /* not lint */
@@ -77,10 +77,10 @@ static const char rcsid[] =
struct nlist nl[] = {
#define N_NFSSTAT 0
- { "nfsstats" },
+ { .n_name = "nfsstats" },
#define N_NFSRVSTAT 1
- { "nfsrvstats" },
- "",
+ { .n_name = "nfsrvstats" },
+ { .n_name = NULL },
};
kvm_t *kd;
@@ -198,7 +198,7 @@ main(int argc, char **argv)
* Read the nfs stats using sysctl(3) for live kernels, or kvm_read
* for dead ones.
*/
-void
+static void
readstats(struct nfsstats **stp, struct nfsrvstats **srvstp, int zero)
{
union {
OpenPOWER on IntegriCloud