From: Jim Meyering Date: Sat, 3 Apr 1999 05:20:06 +0000 (+0000) Subject: Use PROGRAM_NAME in place of string in parse_long_options call. X-Git-Tag: FILEUTILS-4_0e~20 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=cf691ec714de68d0a2d0dec53704b02e2ab52009;p=thirdparty%2Fcoreutils.git Use PROGRAM_NAME in place of string in parse_long_options call. --- diff --git a/src/cat.c b/src/cat.c index 503efe7e54..38596731c2 100644 --- a/src/cat.c +++ b/src/cat.c @@ -534,7 +534,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "cat", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Torbjorn Granlund and Richard M. Stallman", usage); /* Parse command line options. */ diff --git a/src/cksum.c b/src/cksum.c index 2f3cf38c89..60ed6d4c8d 100644 --- a/src/cksum.c +++ b/src/cksum.c @@ -290,7 +290,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "cksum", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Q. Frank Xia", usage); have_read_stdin = 0; diff --git a/src/comm.c b/src/comm.c index 774aee07f8..504a15763e 100644 --- a/src/comm.c +++ b/src/comm.c @@ -217,7 +217,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "comm", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Richard Stallman and David MacKenzie", usage); only_file_1 = 1; diff --git a/src/csplit.c b/src/csplit.c index b993ecd374..9e1148c6f0 100644 --- a/src/csplit.c +++ b/src/csplit.c @@ -1375,7 +1375,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "csplit", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Stuart Kemp and David MacKenzie", usage); global_argv = argv; diff --git a/src/cut.c b/src/cut.c index 05bf8433d3..94360c1e04 100644 --- a/src/cut.c +++ b/src/cut.c @@ -692,7 +692,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "cut", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "David Ihnat, David MacKenzie, and Jim Meyering", usage); operating_mode = undefined_mode; diff --git a/src/expand.c b/src/expand.c index b1c448ea9d..d4484842bb 100644 --- a/src/expand.c +++ b/src/expand.c @@ -336,7 +336,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "expand", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "David MacKenzie", usage); while ((c = getopt_long (argc, argv, "it:,0123456789", longopts, NULL)) != -1) diff --git a/src/fmt.c b/src/fmt.c index 81f6917543..bc1a97a877 100644 --- a/src/fmt.c +++ b/src/fmt.c @@ -313,7 +313,7 @@ main (register int argc, register char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "fmt", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Ross Paterson", usage); crown = tagged = split = uniform = FALSE; diff --git a/src/fold.c b/src/fold.c index a3c387ec98..630a2f8c45 100644 --- a/src/fold.c +++ b/src/fold.c @@ -239,7 +239,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "fold", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "David MacKenzie", usage); break_spaces = count_bytes = have_read_stdin = 0; diff --git a/src/head.c b/src/head.c index ad03cdd4a3..3a890dfa50 100644 --- a/src/head.c +++ b/src/head.c @@ -264,7 +264,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "head", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "David MacKenzie", usage); have_read_stdin = 0; diff --git a/src/join.c b/src/join.c index e74bbab678..8073a56364 100644 --- a/src/join.c +++ b/src/join.c @@ -740,7 +740,7 @@ main (int argc, char **argv) it may be increased. */ uni_blank.nfields = 1; - parse_long_options (argc, argv, "join", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Mike Haertel", usage); nfiles = 0; diff --git a/src/md5sum.c b/src/md5sum.c index c0973fb00b..93ae441341 100644 --- a/src/md5sum.c +++ b/src/md5sum.c @@ -475,7 +475,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "md5sum", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Ulrich Drepper", usage); while ((opt = getopt_long (argc, argv, "bctw", long_options, NULL)) != -1) diff --git a/src/nl.c b/src/nl.c index b0b3c85dd0..6f686875de 100644 --- a/src/nl.c +++ b/src/nl.c @@ -448,7 +448,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "nl", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Scott Bartram and David MacKenzie", usage); have_read_stdin = 0; diff --git a/src/od.c b/src/od.c index dd2176282c..42a2cd956c 100644 --- a/src/od.c +++ b/src/od.c @@ -1596,7 +1596,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "od", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Jim Meyering", usage); err = 0; diff --git a/src/paste.c b/src/paste.c index bdf31ccdea..d3a6488836 100644 --- a/src/paste.c +++ b/src/paste.c @@ -434,7 +434,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "paste", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "David M. Ihnat", usage); have_read_stdin = 0; diff --git a/src/pr.c b/src/pr.c index 43ab930eae..87729d4a08 100644 --- a/src/pr.c +++ b/src/pr.c @@ -825,7 +825,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "pr", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Pete TerMaat and Roland Huebner", usage); n_files = 0; diff --git a/src/ptx.c b/src/ptx.c index 75c4f94b0d..06a315b9a0 100644 --- a/src/ptx.c +++ b/src/ptx.c @@ -1966,7 +1966,7 @@ main (int argc, char **argv) setchrclass (NULL); #endif - parse_long_options (argc, argv, "ptx", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "François Pinard", usage); while (optchar = getopt_long (argc, argv, "ACF:GM:ORS:TW:b:i:fg:o:trw:", diff --git a/src/sort.c b/src/sort.c index 20c05e152e..c0c98ead78 100644 --- a/src/sort.c +++ b/src/sort.c @@ -2528,7 +2528,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "sort", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Mike Haertel", usage); have_read_stdin = 0; diff --git a/src/split.c b/src/split.c index 9a0407c516..a350aa8759 100644 --- a/src/split.c +++ b/src/split.c @@ -345,7 +345,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "split", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Torbjorn Granlund and Richard M. Stallman", usage); /* Parse command line options. */ diff --git a/src/sum.c b/src/sum.c index c2c7fc076a..8a76c23e0c 100644 --- a/src/sum.c +++ b/src/sum.c @@ -212,7 +212,7 @@ main (int argc, char **argv) have_read_stdin = 0; - parse_long_options (argc, argv, "sum", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Kayvan Aghaiepour and David MacKenzie", usage); while ((optc = getopt_long (argc, argv, "rs", longopts, NULL)) != -1) diff --git a/src/tac.c b/src/tac.c index ca640b81e7..dca32bde45 100644 --- a/src/tac.c +++ b/src/tac.c @@ -612,7 +612,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "tac", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Jay Lepreau and David MacKenzie", usage); errors = 0; diff --git a/src/tail.c b/src/tail.c index 09ef59edaf..0f0177a551 100644 --- a/src/tail.c +++ b/src/tail.c @@ -1340,7 +1340,7 @@ main (int argc, char **argv) have_read_stdin = 0; - parse_long_options (argc, argv, "tail", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Paul Rubin, David MacKenzie, Ian Lance Taylor, and Jim Meyering", usage); diff --git a/src/tr.c b/src/tr.c index 75c763a10b..8e52293e74 100644 --- a/src/tr.c +++ b/src/tr.c @@ -1801,7 +1801,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "tr", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Jim Meyering", usage); while ((c = getopt_long (argc, argv, "cdst", long_options, NULL)) != -1) diff --git a/src/tsort.c b/src/tsort.c index 3cf94799e2..e7fdc349e6 100644 --- a/src/tsort.c +++ b/src/tsort.c @@ -459,7 +459,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "tsort", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Mark Kettenis", usage); while ((opt = getopt_long (argc, argv, "", long_options, NULL)) != -1) diff --git a/src/unexpand.c b/src/unexpand.c index e9ed348eab..22fa0fd664 100644 --- a/src/unexpand.c +++ b/src/unexpand.c @@ -387,7 +387,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "unexpand", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "David MacKenzie", usage); have_read_stdin = 0; diff --git a/src/uniq.c b/src/uniq.c index b08f190f86..c3457c302b 100644 --- a/src/uniq.c +++ b/src/uniq.c @@ -287,7 +287,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "uniq", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Richard Stallman and David MacKenzie", usage); skip_chars = 0; diff --git a/src/wc.c b/src/wc.c index 9750a774b2..db2365c96f 100644 --- a/src/wc.c +++ b/src/wc.c @@ -300,7 +300,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - parse_long_options (argc, argv, "wc", GNU_PACKAGE, VERSION, + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, "Paul Rubin and David MacKenzie", usage); exit_status = 0;