commit 5d0abb92aae6f0693713cd407070257022380079
parent e6a5c736cbf01e47bfb2b45c0372671b119812f8
Author: sin <sin@2f30.org>
Date: Tue, 3 Mar 2015 13:37:15 +0000
Staticise globals in col(1)
Diffstat:
M | col.c | | | 20 | ++++++++++---------- |
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/col.c b/col.c
@@ -10,17 +10,11 @@
#define NLINES 256
#define NCOLS 800
-char **buff;
+static char **buff;
-int obackspace, onotabs, ohalfline, oescape;
-unsigned nline, ncol, nchar, nspaces, maxline, bs;
-size_t pagsize = NLINES;
-
-static void
-usage(void)
-{
- enprintf(2, "usage: %s [-p][-l num][-b][-f][-x]\n", argv0);
-}
+static int obackspace, onotabs, ohalfline, oescape;
+static unsigned nline, ncol, nchar, nspaces, maxline, bs;
+static size_t pagsize = NLINES;
static void
flush(void)
@@ -188,6 +182,12 @@ allocbuf(void)
*bp = emalloc(NCOLS);
}
+static void
+usage(void)
+{
+ enprintf(2, "usage: %s [-p][-l num][-b][-f][-x]\n", argv0);
+}
+
int
main(int argc, char *argv[])
{