diff options
author | ru <ru@FreeBSD.org> | 2001-07-10 17:09:00 +0000 |
---|---|---|
committer | ru <ru@FreeBSD.org> | 2001-07-10 17:09:00 +0000 |
commit | 8d6dea3a5542a987c08a218c28776d3751d6878d (patch) | |
tree | 815804646c42fb89b4a8005be0c1f82d27b95463 /contrib/groff/src/utils/addftinfo/addftinfo.cc | |
parent | 9ea23f4150d8e9a0b84050876c26239addf73c8c (diff) | |
download | FreeBSD-src-8d6dea3a5542a987c08a218c28776d3751d6878d.zip FreeBSD-src-8d6dea3a5542a987c08a218c28776d3751d6878d.tar.gz |
Virgin import of FSF groff v1.17.2
Diffstat (limited to 'contrib/groff/src/utils/addftinfo/addftinfo.cc')
-rw-r--r-- | contrib/groff/src/utils/addftinfo/addftinfo.cc | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/contrib/groff/src/utils/addftinfo/addftinfo.cc b/contrib/groff/src/utils/addftinfo/addftinfo.cc index 43a81bc..eb222d9 100644 --- a/contrib/groff/src/utils/addftinfo/addftinfo.cc +++ b/contrib/groff/src/utils/addftinfo/addftinfo.cc @@ -31,6 +31,8 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include "cset.h" #include "guess.h" +extern "C" const char *Version_string; + static void usage(FILE *stream); static void usage(); static void version(); @@ -67,7 +69,8 @@ static struct { int main(int argc, char **argv) { program_name = argv[0]; - for (int i = 1; i < argc; i++) { + int i; + for (i = 1; i < argc; i++) { if (!strcmp(argv[i], "-v") || !strcmp(argv[i],"--version")) version(); if (!strcmp(argv[i],"--help")) { @@ -99,7 +102,6 @@ int main(int argc, char **argv) param.comma_depth = DEFAULT_COMMA_DEPTH; param.desc_depth = DEFAULT_DESC_DEPTH; param.body_depth = DEFAULT_BODY_DEPTH; - int i; for (i = 1; i < argc && argv[i][0] == '-'; i++) { if (argv[i][1] == '-' && argv[i][2] == '\0') { i++; @@ -107,7 +109,7 @@ int main(int argc, char **argv) } if (i + 1 >= argc) usage(); - int j; + size_t j; for (j = 0;; j++) { if (j >= sizeof(param_table)/sizeof(param_table[0])) fatal("parameter `%1' not recognized", argv[i] + 1); @@ -142,7 +144,6 @@ static void usage() static void version() { - extern const char *Version_string; printf("GNU addftinfo (groff) version %s\n", Version_string); exit(0); } |