diff options
author | ed <ed@FreeBSD.org> | 2011-12-13 09:01:44 +0000 |
---|---|---|
committer | ed <ed@FreeBSD.org> | 2011-12-13 09:01:44 +0000 |
commit | be30d3045736836c9dc1bbc09ffb3e17094c4b73 (patch) | |
tree | be9567ca2b8c354913a3e5cfd9917170ae1a16fd /sbin/dumpfs | |
parent | 6487a966c893ce051413fd3dc82e9a1469109d43 (diff) | |
download | FreeBSD-src-be30d3045736836c9dc1bbc09ffb3e17094c4b73.zip FreeBSD-src-be30d3045736836c9dc1bbc09ffb3e17094c4b73.tar.gz |
Staticify dumpfs.
This tool only consists of a single C file, so we can simply mark
everything except main() static. This seems to shave off about 8% of the
binary size.
Diffstat (limited to 'sbin/dumpfs')
-rw-r--r-- | sbin/dumpfs/dumpfs.c | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/sbin/dumpfs/dumpfs.c b/sbin/dumpfs/dumpfs.c index a21f2f2..3451bcd 100644 --- a/sbin/dumpfs/dumpfs.c +++ b/sbin/dumpfs/dumpfs.c @@ -79,16 +79,16 @@ static const char rcsid[] = static struct uufsd disk; -int dumpfs(const char *); -int dumpfsid(void); -int dumpcg(void); -int dumpfreespace(const char *, int); -void dumpfreespacecg(int); -int marshal(const char *); -void pbits(void *, int); -void pblklist(void *, int, off_t, int); -void ufserr(const char *); -void usage(void) __dead2; +static int dumpfs(const char *); +static int dumpfsid(void); +static int dumpcg(void); +static int dumpfreespace(const char *, int); +static void dumpfreespacecg(int); +static int marshal(const char *); +static void pbits(void *, int); +static void pblklist(void *, int, off_t, int); +static void ufserr(const char *); +static void usage(void) __dead2; int main(int argc, char *argv[]) @@ -143,7 +143,7 @@ main(int argc, char *argv[]) exit(eval); } -int +static int dumpfsid(void) { @@ -151,7 +151,7 @@ dumpfsid(void) return 0; } -int +static int dumpfs(const char *name) { time_t fstime; @@ -309,7 +309,7 @@ err: ufserr(name); return (1); } -int +static int dumpcg(void) { time_t cgtime; @@ -370,7 +370,7 @@ dumpcg(void) return (0); } -int +static int dumpfreespace(const char *name, int fflag) { int i; @@ -386,7 +386,7 @@ err: return (1); } -void +static void dumpfreespacecg(int fflag) { @@ -394,7 +394,7 @@ dumpfreespacecg(int fflag) fflag); } -int +static int marshal(const char *name) { struct fs *fs; @@ -444,7 +444,7 @@ marshal(const char *name) return 0; } -void +static void pbits(void *vp, int max) { int i; @@ -466,7 +466,7 @@ pbits(void *vp, int max) printf("\n"); } -void +static void pblklist(void *vp, int max, off_t offset, int fflag) { int i, j; @@ -487,7 +487,7 @@ pblklist(void *vp, int max, off_t offset, int fflag) } } -void +static void ufserr(const char *name) { if (disk.d_error != NULL) @@ -496,7 +496,7 @@ ufserr(const char *name) warn("%s", name); } -void +static void usage(void) { (void)fprintf(stderr, "usage: dumpfs [-fm] filesys | device\n"); |