Whamcloud - gitweb
Adjust badblocks -n/-w exclusive usage message
authorTheodore Ts'o <tytso@mit.edu>
Sat, 18 Nov 2006 04:00:19 +0000 (23:00 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Sat, 18 Nov 2006 04:00:19 +0000 (23:00 -0500)
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
misc/ChangeLog
misc/badblocks.c

index de52b1d..ead69fe 100644 (file)
@@ -1,3 +1,9 @@
+2006-11-17  Theodore Tso  <tytso@mit.edu>
+
+       * badblocks.c (exclusive_usage): Print the program name in the
+               exclusive usage() and don't print the full usage message
+               if the user specifies -n and -w options simultaneously.
+
 2006-11-14  Theodore Tso  <tytso@mit.edu>
 
        * mke2fs.c (PRS): Always allocate the replacement PATH environment
index 9867668..8f48c88 100644 (file)
@@ -84,8 +84,9 @@ static void usage(void)
 static void exclusive_usage(void)
 {
        fprintf(stderr, 
-               _("The -n and -w options are mutually exclusive.\n\n"));
-       usage();
+               _("%s: The -n and -w options are mutually exclusive.\n\n"), 
+               program_name);
+       exit(1);
 }
 
 static unsigned long currently_testing = 0;