summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2003-03-11 20:48:36 +0000
committerJim Meyering <jim@meyering.net>2003-03-11 20:48:36 +0000
commita988982b19c08c43d273db12c487ffac329aefd9 (patch)
tree857b92d96fce14c70ee578da6337a308fc6debb4
parent872d7656339bfe6fd51000ca8129bcc93b6cd0fc (diff)
downloadcoreutils-a988982b19c08c43d273db12c487ffac329aefd9.tar.xz
(longopts): Don't hard-code `2' here.
Instead, just specify `&verbose', and ... (main): ... remove the `case 2:' block for --verbose.
-rw-r--r--src/split.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/split.c b/src/split.c
index 9572e4ec6..793f035a0 100644
--- a/src/split.c
+++ b/src/split.c
@@ -79,7 +79,7 @@ static struct option const longopts[] =
{"lines", required_argument, NULL, 'l'},
{"line-bytes", required_argument, NULL, 'C'},
{"suffix-length", required_argument, NULL, 'a'},
- {"verbose", no_argument, NULL, 2},
+ {"verbose", no_argument, &verbose, 0},
{GETOPT_HELP_OPTION_DECL},
{GETOPT_VERSION_OPTION_DECL},
{NULL, 0, NULL, 0}
@@ -456,10 +456,6 @@ main (int argc, char **argv)
accum = accum * 10 + c - '0';
break;
- case 2:
- verbose = 1;
- break;
-
case_GETOPT_HELP_CHAR;
case_GETOPT_VERSION_CHAR (PROGRAM_NAME, AUTHORS);