From owner-svn-src-head@FreeBSD.ORG Sun Nov 6 08:17:06 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9340B1066768; Sun, 6 Nov 2011 08:17:06 +0000 (UTC) (envelope-from ed@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3CC4C8FC0C; Sun, 6 Nov 2011 08:17:06 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id pA68H64V009070; Sun, 6 Nov 2011 08:17:06 GMT (envelope-from ed@svn.freebsd.org) Received: (from ed@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id pA68H6LH009068; Sun, 6 Nov 2011 08:17:06 GMT (envelope-from ed@svn.freebsd.org) Message-Id: <201111060817.pA68H6LH009068@svn.freebsd.org> From: Ed Schouten Date: Sun, 6 Nov 2011 08:17:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r227182 - head/usr.bin/seq X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 06 Nov 2011 08:17:06 -0000 Author: ed Date: Sun Nov 6 08:17:05 2011 New Revision: 227182 URL: http://svn.freebsd.org/changeset/base/227182 Log: Add missing static keywords to seq(1) Modified: head/usr.bin/seq/seq.c Modified: head/usr.bin/seq/seq.c ============================================================================== --- head/usr.bin/seq/seq.c Sun Nov 6 08:16:59 2011 (r227181) +++ head/usr.bin/seq/seq.c Sun Nov 6 08:17:05 2011 (r227182) @@ -51,20 +51,19 @@ __FBSDID("$FreeBSD$"); /* Globals */ -const char *decimal_point = "."; /* default */ -char default_format[] = { "%g" }; /* default */ +static const char *decimal_point = "."; /* default */ +static char default_format[] = { "%g" }; /* default */ /* Prototypes */ -double e_atof(const char *); +static double e_atof(const char *); -int decimal_places(const char *); -int main(int, char *[]); -int numeric(const char *); -int valid_format(const char *); +static int decimal_places(const char *); +static int numeric(const char *); +static int valid_format(const char *); -char *generate_format(double, double, double, int, char); -char *unescape(char *); +static char *generate_format(double, double, double, int, char); +static char *unescape(char *); /* * The seq command will print out a numeric sequence from 1, the default, @@ -186,7 +185,7 @@ main(int argc, char *argv[]) /* * numeric - verify that string is numeric */ -int +static int numeric(const char *s) { int seen_decimal_pt, decimal_pt_len; @@ -223,7 +222,7 @@ numeric(const char *s) /* * valid_format - validate user specified format string */ -int +static int valid_format(const char *fmt) { int conversions = 0; @@ -268,7 +267,7 @@ valid_format(const char *fmt) /* * unescape - handle C escapes in a string */ -char * +static char * unescape(char *orig) { char c, *cp, *new = orig; @@ -358,7 +357,7 @@ unescape(char *orig) * exit if string is not a valid double, or if converted value would * cause overflow or underflow */ -double +static double e_atof(const char *num) { char *endp; @@ -383,7 +382,7 @@ e_atof(const char *num) /* * decimal_places - count decimal places in a number (string) */ -int +static int decimal_places(const char *number) { int places = 0; @@ -405,7 +404,7 @@ decimal_places(const char *number) * XXX to be bug for bug compatible with Plan9 and GNU return "%g" * when "%g" prints as "%e" (this way no width adjustments are made) */ -char * +static char * generate_format(double first, double incr, double last, int equalize, char pad) { static char buf[256];