summaryrefslogtreecommitdiff
path: root/util-linux/mkswap.c
diff options
context:
space:
mode:
authorEric Andersen2001-02-14 21:23:06 +0000
committerEric Andersen2001-02-14 21:23:06 +0000
commit67991cf824f8df27e74c92d754fb507681c69ce6 (patch)
treea0b652f3dc794d1050c1a8de3afb014a621238fa /util-linux/mkswap.c
parent68be2ab914e1e20fe666bbd22a89a18714be2789 (diff)
downloadbusybox-67991cf824f8df27e74c92d754fb507681c69ce6.zip
busybox-67991cf824f8df27e74c92d754fb507681c69ce6.tar.gz
This patch, put together by Manuel Novoa III, is a merge of work
done by Evin Robertson (bug#1105) and work from Manuel to make usage messages occupy less space and simplify how usage messages are displayed.
Diffstat (limited to 'util-linux/mkswap.c')
-rw-r--r--util-linux/mkswap.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/util-linux/mkswap.c b/util-linux/mkswap.c
index 7d690ad..48637e8 100644
--- a/util-linux/mkswap.c
+++ b/util-linux/mkswap.c
@@ -287,7 +287,7 @@ int mkswap_main(int argc, char **argv)
PAGES = strtol(argv[0], &tmp, 0) / blocks_per_page;
if (*tmp)
- usage(mkswap_usage);
+ show_usage();
} else
device_name = argv[0];
} else {
@@ -302,13 +302,13 @@ int mkswap_main(int argc, char **argv)
version = atoi(argv[0] + 2);
break;
default:
- usage(mkswap_usage);
+ show_usage();
}
}
}
if (!device_name) {
error_msg("error: Nowhere to set up swap on?");
- usage(mkswap_usage);
+ show_usage();
}
sz = get_size(device_name);
if (!PAGES) {
@@ -331,12 +331,12 @@ int mkswap_main(int argc, char **argv)
}
if (version != 0 && version != 1) {
error_msg("error: unknown version %d", version);
- usage(mkswap_usage);
+ show_usage();
}
if (PAGES < 10) {
error_msg("error: swap area needs to be at least %ldkB",
(long) (10 * pagesize / 1024));
- usage(mkswap_usage);
+ show_usage();
}
#if 0
maxpages = ((version == 0) ? V0_MAX_PAGES : V1_MAX_PAGES);