Module Name: src Committed By: joerg Date: Tue Aug 30 21:36:38 UTC 2011
Modified Files: src/usr.bin/comm: comm.c Log Message: static + __dead To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 src/usr.bin/comm/comm.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/usr.bin/comm/comm.c diff -u src/usr.bin/comm/comm.c:1.18 src/usr.bin/comm/comm.c:1.19 --- src/usr.bin/comm/comm.c:1.18 Sat Nov 28 03:56:38 2009 +++ src/usr.bin/comm/comm.c Tue Aug 30 21:36:38 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: comm.c,v 1.18 2009/11/28 03:56:38 darcy Exp $ */ +/* $NetBSD: comm.c,v 1.19 2011/08/30 21:36:38 joerg Exp $ */ /* * Copyright (c) 1989, 1993, 1994 @@ -42,7 +42,7 @@ #if 0 static char sccsid[] = "@(#)comm.c 8.4 (Berkeley) 5/4/95"; #endif -__RCSID("$NetBSD: comm.c,v 1.18 2009/11/28 03:56:38 darcy Exp $"); +__RCSID("$NetBSD: comm.c,v 1.19 2011/08/30 21:36:38 joerg Exp $"); #endif /* not lint */ #include <err.h> @@ -55,12 +55,12 @@ #define MAXLINELEN (LINE_MAX + 1) -const char *tabs[] = { "", "\t", "\t\t" }; +static const char *tabs[] = { "", "\t", "\t\t" }; -FILE *file(const char *); -void show(FILE *, const char *, char *); -void usage(void); -char *getnextln(char *buf, FILE *); +static FILE *file(const char *); +static void show(FILE *, const char *, char *); +__dead static void usage(void); +static char *getnextln(char *buf, FILE *); int main(int argc, char **argv) @@ -164,14 +164,14 @@ exit(0); } -void +static void show(FILE *fp, const char *offset, char *buf) { while (printf("%s%s\n", offset, buf) >= 0 && getnextln(buf, fp)) ; } -FILE * +static FILE * file(const char *name) { FILE *fp; @@ -183,7 +183,7 @@ return (fp); } -void +static void usage(void) { @@ -191,7 +191,7 @@ exit(1); } -char * +static char * getnextln(char *buf, FILE *fp) { size_t i = 0;