diff options
author | dfr <dfr@FreeBSD.org> | 2008-05-07 13:39:42 +0000 |
---|---|---|
committer | dfr <dfr@FreeBSD.org> | 2008-05-07 13:39:42 +0000 |
commit | 51b6601db456e699ea5d4843cbc7239ee92d9c13 (patch) | |
tree | 4dbb862199a916e3ffe75f1cb08703ec0e662ffc /crypto/heimdal/lib/sl/make_cmds.c | |
parent | 2565fa13487d5bfc858144e431e3dfd7ffa5200e (diff) | |
download | FreeBSD-src-51b6601db456e699ea5d4843cbc7239ee92d9c13.zip FreeBSD-src-51b6601db456e699ea5d4843cbc7239ee92d9c13.tar.gz |
Vendor import of Heimdal 1.1
Diffstat (limited to 'crypto/heimdal/lib/sl/make_cmds.c')
-rw-r--r-- | crypto/heimdal/lib/sl/make_cmds.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/crypto/heimdal/lib/sl/make_cmds.c b/crypto/heimdal/lib/sl/make_cmds.c index 723dfdc..c39be21 100644 --- a/crypto/heimdal/lib/sl/make_cmds.c +++ b/crypto/heimdal/lib/sl/make_cmds.c @@ -34,7 +34,7 @@ #include "make_cmds.h" #include <getarg.h> -RCSID("$Id: make_cmds.c,v 1.7 2001/02/20 01:44:55 assar Exp $"); +RCSID("$Id: make_cmds.c 15430 2005-06-16 19:25:45Z lha $"); #include <roken.h> #include <err.h> @@ -113,7 +113,7 @@ generate_commands(void) { char *base; char *cfn; - char *p; + char *p, *q; p = strrchr(table_name, '/'); if(p == NULL) @@ -145,7 +145,6 @@ generate_commands(void) { struct command_list *cl, *xl; - char *p, *q; for(cl = commands; cl; cl = cl->next) { for(xl = commands; xl != cl; xl = xl->next) @@ -211,10 +210,10 @@ usage(int code) int main(int argc, char **argv) { - int optind = 0; + int optidx = 0; setprogname(argv[0]); - if(getarg(args, num_args, argc, argv, &optind)) + if(getarg(args, num_args, argc, argv, &optidx)) usage(1); if(help_flag) usage(0); @@ -223,9 +222,9 @@ main(int argc, char **argv) exit(0); } - if(argc == optind) + if(argc == optidx) usage(1); - filename = argv[optind]; + filename = argv[optidx]; yyin = fopen(filename, "r"); if(yyin == NULL) err(1, "%s", filename); |