Signed-off-by: Francesco Cosoleto <cosoleto@xxxxxxxxx> --- disk-utils/isosize.c | 10 +++------- 1 files changed, 3 insertions(+), 7 deletions(-) diff --git a/disk-utils/isosize.c b/disk-utils/isosize.c index 36c9387..4583a5f 100644 --- a/disk-utils/isosize.c +++ b/disk-utils/isosize.c @@ -25,6 +25,7 @@ #include <unistd.h> #include <string.h> #include <err.h> +#include <errno.h> #include "nls.h" @@ -117,7 +118,6 @@ struct iso_primary_descriptor { unsigned char unused5 [ISODCL (1396, 2048)]; }; -const char *progname; int divisor = 0; static void @@ -159,17 +159,13 @@ main(int argc, char * argv[]) { int j, ct; char *p; - progname = argv[0]; - if ((p = strrchr(progname, '/')) != NULL) - progname = p+1; - setlocale(LC_ALL, ""); bindtextdomain(PACKAGE, LOCALEDIR); textdomain(PACKAGE); if (argc >= 2 && (!strcmp(argv[1], "-V") || !strcmp(argv[1], "--version"))) { - printf(_("%s (%s)\n"), progname, PACKAGE_STRING); + printf(_("%s (%s)\n"), program_invocation_short_name, PACKAGE_STRING); exit(0); } @@ -195,7 +191,7 @@ main(int argc, char * argv[]) { if (ct <= 0) { fprintf(stderr, _("Usage: %s [-x] [-d <num>] iso9660-image\n"), - progname); + program_invocation_short_name); exit(1); } -- 1.7.1 -- To unsubscribe from this list: send the line "unsubscribe util-linux" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html