summaryrefslogtreecommitdiff
path: root/src/comm.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1999-04-04 15:44:26 +0000
committerJim Meyering <jim@meyering.net>1999-04-04 15:44:26 +0000
commitd815c152dfb4d796fce6debeaaf14f2ae5534337 (patch)
treebd7ddbcf36af5d84e3485faeaeb8ea38c8d58579 /src/comm.c
parent25abb410d417faa40faa7833c55e19ee2819f804 (diff)
downloadcoreutils-d815c152dfb4d796fce6debeaaf14f2ae5534337.tar.xz
Standardize --help and --version processing.
Diffstat (limited to 'src/comm.c')
-rw-r--r--src/comm.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/comm.c b/src/comm.c
index c7be39b1a..9aab98b02 100644
--- a/src/comm.c
+++ b/src/comm.c
@@ -24,7 +24,6 @@
#include <sys/types.h>
#include "system.h"
#include "linebuffer.h"
-#include "long-options.h"
#include "error.h"
/* The official name of this program (e.g., no `g' prefix). */
@@ -50,6 +49,8 @@ static int both;
static struct option const long_options[] =
{
+ {GETOPT_HELP_OPTION_DECL},
+ {GETOPT_VERSION_OPTION_DECL},
{0, 0, 0, 0}
};
@@ -219,9 +220,6 @@ main (int argc, char **argv)
bindtextdomain (PACKAGE, LOCALEDIR);
textdomain (PACKAGE);
- parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION,
- AUTHORS, usage);
-
only_file_1 = 1;
only_file_2 = 1;
both = 1;
@@ -244,6 +242,10 @@ main (int argc, char **argv)
both = 0;
break;
+ case_GETOPT_HELP_CHAR;
+
+ case_GETOPT_VERSION_CHAR (PROGRAM_NAME, AUTHORS);
+
default:
usage (1);
}