diff options
author | Jim Meyering <jim@meyering.net> | 1999-01-14 18:25:16 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 1999-01-14 18:25:16 +0000 |
commit | 9fec9172beaf67d1e16ae13b1f3ac44135cc8363 (patch) | |
tree | d787cf23dce38b0e2af16cc93c345f106c095801 /src | |
parent | da258119328fe4af0e0aa0d6f292600732aa0bb4 (diff) | |
download | coreutils-9fec9172beaf67d1e16ae13b1f3ac44135cc8363.tar.xz |
Don't prototype usage as static.
Diffstat (limited to 'src')
-rw-r--r-- | src/cat.c | 2 | ||||
-rw-r--r-- | src/cksum.c | 2 | ||||
-rw-r--r-- | src/comm.c | 2 | ||||
-rw-r--r-- | src/csplit.c | 4 | ||||
-rw-r--r-- | src/cut.c | 2 | ||||
-rw-r--r-- | src/expand.c | 2 | ||||
-rw-r--r-- | src/fmt.c | 2 | ||||
-rw-r--r-- | src/fold.c | 2 | ||||
-rw-r--r-- | src/head.c | 3 | ||||
-rw-r--r-- | src/join.c | 2 | ||||
-rw-r--r-- | src/md5sum.c | 2 | ||||
-rw-r--r-- | src/nl.c | 2 | ||||
-rw-r--r-- | src/od.c | 3 | ||||
-rw-r--r-- | src/paste.c | 2 | ||||
-rw-r--r-- | src/pr.c | 5 | ||||
-rw-r--r-- | src/ptx.c | 10 | ||||
-rw-r--r-- | src/sort.c | 2 | ||||
-rw-r--r-- | src/split.c | 2 | ||||
-rw-r--r-- | src/sum.c | 2 | ||||
-rw-r--r-- | src/tac.c | 2 | ||||
-rw-r--r-- | src/tail.c | 6 | ||||
-rw-r--r-- | src/tr.c | 2 | ||||
-rw-r--r-- | src/tsort.c | 3 | ||||
-rw-r--r-- | src/unexpand.c | 2 | ||||
-rw-r--r-- | src/uniq.c | 2 | ||||
-rw-r--r-- | src/wc.c | 2 |
26 files changed, 32 insertions, 40 deletions
@@ -72,7 +72,7 @@ static int newlines2 = 0; /* Count of non-fatal error conditions. */ static int exit_status = 0; -static void +void usage (int status) { if (status != 0) diff --git a/src/cksum.c b/src/cksum.c index 81d745d80..ad389827a 100644 --- a/src/cksum.c +++ b/src/cksum.c @@ -260,7 +260,7 @@ cksum (char *file, int print_name) return 0; } -static void +void usage (int status) { if (status != 0) diff --git a/src/comm.c b/src/comm.c index ef27f81dd..f2cf9953e 100644 --- a/src/comm.c +++ b/src/comm.c @@ -57,7 +57,7 @@ static struct option const long_options[] = -static void +void usage (int status) { if (status != 0) diff --git a/src/csplit.c b/src/csplit.c index fe007eb5f..17fca156e 100644 --- a/src/csplit.c +++ b/src/csplit.c @@ -123,7 +123,7 @@ static void close_output_file PARAMS ((void)); static void create_output_file PARAMS ((void)); static void delete_all_files PARAMS ((void)); static void save_line_to_file PARAMS ((const struct cstring *line)); -static void usage PARAMS ((int status)); +void usage PARAMS ((int status)); /* The name this program was run with. */ char *program_name; @@ -1496,7 +1496,7 @@ main (int argc, char **argv) exit (EXIT_SUCCESS); } -static void +void usage (int status) { if (status != 0) @@ -187,7 +187,7 @@ static struct option const longopts[] = {0, 0, 0, 0} }; -static void +void usage (int status) { if (status != 0) diff --git a/src/expand.c b/src/expand.c index 84f589a93..ecb4590b2 100644 --- a/src/expand.c +++ b/src/expand.c @@ -98,7 +98,7 @@ static struct option const longopts[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) @@ -262,7 +262,7 @@ static int next_prefix_indent; paragraphs chosen by fmt_paragraph(). */ static int last_line_length; -static void +void usage (int status) { if (status != 0) diff --git a/src/fold.c b/src/fold.c index 14868b343..e51bdde71 100644 --- a/src/fold.c +++ b/src/fold.c @@ -55,7 +55,7 @@ static struct option const longopts[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) diff --git a/src/head.c b/src/head.c index 474ff8bc5..a698c2dd8 100644 --- a/src/head.c +++ b/src/head.c @@ -76,7 +76,7 @@ static struct option const long_options[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) @@ -342,7 +342,6 @@ main (int argc, char **argv) } - while ((c = getopt_long (argc, argv, "c:n:qv", long_options, NULL)) != -1) { switch (c) diff --git a/src/join.c b/src/join.c index 72264f378..30c27c551 100644 --- a/src/join.c +++ b/src/join.c @@ -127,7 +127,7 @@ static struct line uni_blank; /* If nonzero, ignore case when comparing join fields. */ static int ignore_case; -static void +void usage (int status) { if (status != 0) diff --git a/src/md5sum.c b/src/md5sum.c index 5e364b524..480328583 100644 --- a/src/md5sum.c +++ b/src/md5sum.c @@ -93,7 +93,7 @@ static const struct option long_options[] = { NULL, 0, NULL, 0 } }; -static void +void usage (int status) { if (status != 0) @@ -165,7 +165,7 @@ static struct option const longopts[] = /* Print a usage message and quit. */ -static void +void usage (int status) { if (status != 0) @@ -37,7 +37,6 @@ typedef long double LONG_DOUBLE; typedef double LONG_DOUBLE; #endif - #if HAVE_VALUES_H # include <values.h> #endif @@ -264,7 +263,7 @@ static struct option const long_options[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) diff --git a/src/paste.c b/src/paste.c index 4136133c4..21f7a0cb9 100644 --- a/src/paste.c +++ b/src/paste.c @@ -399,7 +399,7 @@ paste_serial (int nfiles, char **fnamptr) return errors; } -static void +void usage (int status) { if (status != 0) @@ -29,7 +29,6 @@ Improve the printing of control prefixes. - Options: +FIRST_PAGE[:LAST_PAGE] @@ -270,7 +269,7 @@ static void pad_across_to PARAMS ((int position)); static void add_line_number PARAMS ((COLUMN *p)); static void getoptarg PARAMS ((char *arg, char switch_char, char *character, int *number)); -static void usage PARAMS ((int status)); +void usage PARAMS ((int status)); static void print_files PARAMS ((int number_of_files, char **av)); static void init_parameters PARAMS ((int number_of_files)); static void init_header PARAMS ((char *filename, int desc)); @@ -2438,7 +2437,7 @@ cleanup (void) /* Complain, print a usage message, and die. */ -static void +void usage (int status) { if (status != 0) @@ -176,7 +176,6 @@ int maximum_word_length; /* Maximum width of any reference used. */ int reference_max_width; - /* Ignore and Only word tables. */ WORD_TABLE ignore_table; /* table of words to ignore */ @@ -269,7 +268,6 @@ size_t number_of_occurs[1]; /* number of used slots in occurs_table */ #define ALLOC_NEW_OCCURS(language) \ BUMP_ALLOC (occurs_table[language], number_of_occurs[language], 9, OCCURS) - /* Communication among output routines. */ /* Indicate if special output processing is requested for each character. */ @@ -1810,7 +1808,6 @@ generate_all_output (void) int occurs_index; /* index of keyword entry being processed */ OCCURS *occurs_cursor; /* current keyword entry being processed */ - /* The following assignments are useful to provide default values in case line contexts or references are not used, in which case these variables would never be computed. */ @@ -1823,7 +1820,6 @@ generate_all_output (void) head.end = NULL; head_truncation = 0; - /* Loop over all keyword occurrences. */ occurs_cursor = occurs_table[0]; @@ -1867,7 +1863,7 @@ generate_all_output (void) | Print program identification and options, then exit. | `------------------------------------------------------*/ -static void +void usage (int status) { if (status != EXIT_SUCCESS) @@ -2064,8 +2060,8 @@ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n"), break; case 10: - XARGMATCH (&output_format, "--format", optarg, - format_args, format_vals, usage (1)); + output_format = XARGMATCH ("--format", optarg, + format_args, format_vals); } } diff --git a/src/sort.c b/src/sort.c index 6e76059df..9636547eb 100644 --- a/src/sort.c +++ b/src/sort.c @@ -269,7 +269,7 @@ static int have_read_stdin; /* Lists of key field comparisons to be tried. */ static struct keyfield keyhead; -static void +void usage (int status) { if (status != 0) diff --git a/src/split.c b/src/split.c index 288ee5ec9..938c5d1df 100644 --- a/src/split.c +++ b/src/split.c @@ -77,7 +77,7 @@ static struct option const longopts[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) @@ -51,7 +51,7 @@ static struct option const longopts[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) @@ -109,7 +109,7 @@ static struct option const longopts[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) diff --git a/src/tail.c b/src/tail.c index a8edb5769..90d8d49b4 100644 --- a/src/tail.c +++ b/src/tail.c @@ -183,7 +183,7 @@ static struct option const long_options[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) @@ -1268,8 +1268,8 @@ parse_options (int argc, char **argv, if (optarg == NULL) follow_mode = DEFAULT_FOLLOW_MODE; else - XARGMATCH (&follow_mode, "--follow", optarg, - follow_mode_string, follow_mode_map, usage (1)); + follow_mode = XARGMATCH ("--follow", optarg, + follow_mode_string, follow_mode_map); break; case CHAR_MAX + 1: @@ -315,7 +315,7 @@ static struct option const long_options[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) diff --git a/src/tsort.c b/src/tsort.c index 418532d1b..270632ffe 100644 --- a/src/tsort.c +++ b/src/tsort.c @@ -77,7 +77,7 @@ static struct option const long_options[] = { NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) @@ -446,7 +446,6 @@ tsort (const char *file) } } - int main (int argc, char **argv) { diff --git a/src/unexpand.c b/src/unexpand.c index 5c4702494..7768c14cb 100644 --- a/src/unexpand.c +++ b/src/unexpand.c @@ -351,7 +351,7 @@ unexpand (void) } } -static void +void usage (int status) { if (status != 0) diff --git a/src/uniq.c b/src/uniq.c index d02790c2e..9514fa10c 100644 --- a/src/uniq.c +++ b/src/uniq.c @@ -90,7 +90,7 @@ static struct option const longopts[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) @@ -71,7 +71,7 @@ static struct option const longopts[] = {NULL, 0, NULL, 0} }; -static void +void usage (int status) { if (status != 0) |