Do not use __progname.

This commit is contained in:
Philippe Charnier 1997-06-06 06:32:09 +00:00
parent c70e52b140
commit 714ec423a0

View File

@ -1,4 +1,4 @@
/* $Id: chio.c,v 1.1.1.1 1997/03/06 15:30:06 joerg Exp $ */ /* $Id: chio.c,v 1.2 1997/06/02 06:25:19 charnier Exp $ */
/* /*
* Copyright (c) 1996 Jason R. Thorpe <thorpej@and.com> * Copyright (c) 1996 Jason R. Thorpe <thorpej@and.com>
@ -47,8 +47,6 @@
#include "defs.h" #include "defs.h"
#include "pathnames.h" #include "pathnames.h"
extern char *__progname; /* from crt0.o */
static void usage __P((void)); static void usage __P((void));
static void cleanup __P((void)); static void cleanup __P((void));
static int parse_element_type __P((char *)); static int parse_element_type __P((char *));
@ -208,8 +206,8 @@ do_move(cname, argc, argv)
return (0); return (0);
usage: usage:
fprintf(stderr, "usage: %s %s " fprintf(stderr, "usage: chio %s "
"<from ET> <from EU> <to ET> <to EU> [inv]\n", __progname, cname); "<from ET> <from EU> <to ET> <to EU> [inv]\n", cname);
return (1); return (1);
} }
@ -301,9 +299,9 @@ do_exchange(cname, argc, argv)
return (0); return (0);
usage: usage:
fprintf(stderr, "usage: %s %s <src ET> <src EU> <dst1 ET> <dst1 EU>\n" fprintf(stderr,
" [<dst2 ET> <dst2 EU>] [inv1] [inv2]\n", "usage: chio %s <src ET> <src EU> <dst1 ET> <dst1 EU>\n"
__progname, cname); " [<dst2 ET> <dst2 EU>] [inv1] [inv2]\n", cname);
return (1); return (1);
} }
@ -362,8 +360,7 @@ do_position(cname, argc, argv)
return (0); return (0);
usage: usage:
fprintf(stderr, "usage: %s %s <to ET> <to EU> [inv]\n", fprintf(stderr, "usage: chio %s <to ET> <to EU> [inv]\n", cname);
__progname, cname);
return (1); return (1);
} }
@ -399,7 +396,7 @@ do_params(cname, argc, argv)
return (0); return (0);
usage: usage:
fprintf(stderr, "usage: %s %s\n", __progname, cname); fprintf(stderr, "usage: chio %s\n", cname);
return (1); return (1);
} }
@ -426,7 +423,7 @@ do_getpicker(cname, argc, argv)
return (0); return (0);
usage: usage:
fprintf(stderr, "usage: %s %s\n", __progname, cname); fprintf(stderr, "usage: chio %s\n", cname);
return (1); return (1);
} }
@ -455,7 +452,7 @@ do_setpicker(cname, argc, argv)
return (0); return (0);
usage: usage:
fprintf(stderr, "usage: %s %s <picker>\n", __progname, cname); fprintf(stderr, "usage: chio %s <picker>\n", cname);
return (1); return (1);
} }
@ -564,8 +561,7 @@ do_status(cname, argc, argv)
return (0); return (0);
usage: usage:
fprintf(stderr, "usage: %s %s [<element type>]\n", __progname, fprintf(stderr, "usage: chio %s [<element type>]\n", cname);
cname);
return (1); return (1);
} }
@ -662,7 +658,7 @@ usage()
{ {
int i; int i;
fprintf(stderr, "usage: %s [-f changer] command [args ...]\n", __progname); fprintf(stderr, "usage: chio [-f changer] command [args ...]\n");
fprintf(stderr, "commands:"); fprintf(stderr, "commands:");
for (i = 0; commands[i].cc_name; i++) for (i = 0; commands[i].cc_name; i++)
fprintf(stderr, " %s", commands[i].cc_name); fprintf(stderr, " %s", commands[i].cc_name);