From: Wolfgang Denk Date: Thu, 1 Mar 2012 21:19:40 +0000 (+0000) Subject: mkenvimage: fix usage message X-Git-Tag: v2012.04-rc1~17^2^2~15 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=e758a5c4a75eb0d29201422ffc97ef7d95a88df8;p=oweals%2Fu-boot.git mkenvimage: fix usage message Don't use argv[0] for usage() because it may or may not be clobbered by the previous call to basename(). Use "prg" instead as it is done in the rest of the code. Signed-off-by: Wolfgang Denk Acked-by: Mike Frysinger --- diff --git a/tools/mkenvimage.c b/tools/mkenvimage.c index f78173163f..64f5340b1b 100644 --- a/tools/mkenvimage.c +++ b/tools/mkenvimage.c @@ -123,7 +123,7 @@ int main(int argc, char **argv) case ':': fprintf(stderr, "Missing argument for option -%c\n", optopt); - usage(argv[0]); + usage(prg); return EXIT_FAILURE; default: fprintf(stderr, "Wrong option -%c\n", optopt);