tools: use basename in help message
authorLucas De Marchi <lucas.demarchi@profusion.mobi>
Thu, 5 Jan 2012 10:15:51 +0000 (08:15 -0200)
committerLucas De Marchi <lucas.demarchi@profusion.mobi>
Thu, 5 Jan 2012 10:16:28 +0000 (08:16 -0200)
tools/kmod-depmod.c
tools/kmod-insmod.c
tools/kmod-modinfo.c
tools/kmod-rmmod.c

index 9d6761c..7da9d0e 100644 (file)
@@ -2591,7 +2591,7 @@ static int do_depmod(int argc, char *argv[])
                        }
                        break;
                case 'h':
-                       help(argv[0]);
+                       help(basename(argv[0]));
                        free(config_paths);
                        return EXIT_SUCCESS;
                case 'V':
index b071109..3c3e9c8 100644 (file)
@@ -81,7 +81,7 @@ static int do_insmod(int argc, char *argv[])
                        /* ignored, for compatibility only */
                        break;
                case 'h':
-                       help(argv[0]);
+                       help(basename(argv[0]));
                        return EXIT_SUCCESS;
                case 'V':
                        puts(PACKAGE " version " VERSION);
index 38eed2e..b6af26f 100644 (file)
@@ -370,7 +370,7 @@ static int do_modinfo(int argc, char *argv[])
                        root = optarg;
                        break;
                case 'h':
-                       help(argv[0]);
+                       help(basename(argv[0]));
                        return EXIT_SUCCESS;
                case 'V':
                        puts(PACKAGE " version " VERSION);
index 2593128..8945578 100644 (file)
@@ -128,7 +128,7 @@ static int do_rmmod(int argc, char *argv[])
                        flags &= ~KMOD_REMOVE_NOWAIT;
                        break;
                case 'h':
-                       help(argv[0]);
+                       help(basename(argv[0]));
                        return EXIT_SUCCESS;
                case 'V':
                        puts(PACKAGE " version " VERSION);