Author: ed
Date: Sun Nov  6 08:16:35 2011
New Revision: 227177
URL: http://svn.freebsd.org/changeset/base/227177

Log:
  Add missing static keywords to rs(1)

Modified:
  head/usr.bin/rs/rs.c

Modified: head/usr.bin/rs/rs.c
==============================================================================
--- head/usr.bin/rs/rs.c        Sun Nov  6 08:16:29 2011        (r227176)
+++ head/usr.bin/rs/rs.c        Sun Nov  6 08:16:35 2011        (r227177)
@@ -53,7 +53,7 @@ __FBSDID("$FreeBSD$");
 #include <stdlib.h>
 #include <string.h>
 
-long   flags;
+static long    flags;
 #define        TRANSPOSE       000001
 #define        MTRANSPOSE      000002
 #define        ONEPERLINE      000004
@@ -72,34 +72,34 @@ long        flags;
 #define ONEPERCHAR     0100000
 #define NOARGS         0200000
 
-short  *colwidths;
-short  *cord;
-short  *icbd;
-short  *ocbd;
-int    nelem;
-char   **elem;
-char   **endelem;
-char   *curline;
-int    allocsize = BUFSIZ;
-int    curlen;
-int    irows, icols;
-int    orows = 0, ocols = 0;
-int    maxlen;
-int    skip;
-int    propgutter;
-char   isep = ' ', osep = ' ';
-char   blank[] = "";
-int    owidth = 80, gutter = 2;
-
-void     getargs(int, char *[]);
-void     getfile(void);
-int      getline(void);
-char    *getlist(short **, char *);
-char    *getnum(int *, char *, int);
-char   **getptrs(char **);
-void     prepfile(void);
-void     prints(char *, int);
-void     putfile(void);
+static short   *colwidths;
+static short   *cord;
+static short   *icbd;
+static short   *ocbd;
+static int     nelem;
+static char    **elem;
+static char    **endelem;
+static char    *curline;
+static int     allocsize = BUFSIZ;
+static int     curlen;
+static int     irows, icols;
+static int     orows = 0, ocols = 0;
+static int     maxlen;
+static int     skip;
+static int     propgutter;
+static char    isep = ' ', osep = ' ';
+static char    blank[] = "";
+static int     owidth = 80, gutter = 2;
+
+static void      getargs(int, char *[]);
+static void      getfile(void);
+static int       getline(void);
+static char     *getlist(short **, char *);
+static char     *getnum(int *, char *, int);
+static char    **getptrs(char **);
+static void      prepfile(void);
+static void      prints(char *, int);
+static void      putfile(void);
 static void usage(void);
 
 #define        INCR(ep) do {                   \
@@ -121,7 +121,7 @@ main(int argc, char *argv[])
        exit(0);
 }
 
-void
+static void
 getfile(void)
 {
        char *p;
@@ -189,7 +189,7 @@ getfile(void)
        nelem = ep - elem;
 }
 
-void
+static void
 putfile(void)
 {
        char **ep;
@@ -211,7 +211,7 @@ putfile(void)
                }
 }
 
-void
+static void
 prints(char *s, int col)
 {
        int n;
@@ -237,7 +237,7 @@ usage(void)
        exit(1);
 }
 
-void
+static void
 prepfile(void)
 {
        char **ep;
@@ -330,9 +330,9 @@ prepfile(void)
 }
 
 #define        BSIZE   (LINE_MAX * 2)
-char   ibuf[BSIZE];
+static char    ibuf[BSIZE];
 
-int
+static int
 getline(void)  /* get line; maintain curline, curlen; manage storage */
 {
        static  int putlength;
@@ -372,7 +372,7 @@ getline(void)       /* get line; maintain curl
        return(c);
 }
 
-char **
+static char **
 getptrs(char **sp)
 {
        char **p;
@@ -387,7 +387,7 @@ getptrs(char **sp)
        return(sp);
 }
 
-void
+static void
 getargs(int ac, char *av[])
 {
        char *p;
@@ -498,7 +498,7 @@ getargs(int ac, char *av[])
        }
 }
 
-char *
+static char *
 getlist(short **list, char *p)
 {
        int count = 1;
@@ -534,7 +534,7 @@ getlist(short **list, char *p)
  * num = number p points to; if (strict) complain
  * returns pointer to end of num
  */
-char *
+static char *
 getnum(int *num, char *p, int strict)
 {
        char *t = p;
_______________________________________________
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to