diff options
Diffstat (limited to 'free.c')
-rw-r--r-- | free.c | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -25,6 +25,12 @@ | |||
25 | #include <stdio.h> | 25 | #include <stdio.h> |
26 | #include <errno.h> | 26 | #include <errno.h> |
27 | 27 | ||
28 | const char free_usage[] = | ||
29 | "free\n" | ||
30 | #ifndef BB_FEATURE_TRIVIAL_HELP | ||
31 | "\nDisplays the amount of free and used system memory\n" | ||
32 | #endif | ||
33 | ; | ||
28 | 34 | ||
29 | extern int free_main(int argc, char **argv) | 35 | extern int free_main(int argc, char **argv) |
30 | { | 36 | { |
@@ -53,14 +59,8 @@ extern int free_main(int argc, char **argv) | |||
53 | info.sharedram*=info.mem_unit; | 59 | info.sharedram*=info.mem_unit; |
54 | info.bufferram*=info.mem_unit; | 60 | info.bufferram*=info.mem_unit; |
55 | } | 61 | } |
56 | if (argc > 1 && **(argv + 1) == '-') { | 62 | if (argc > 1 && **(argv + 1) == '-') |
57 | usage("free\n" | 63 | usage(free_usage); |
58 | #ifndef BB_FEATURE_TRIVIAL_HELP | ||
59 | "\nDisplays the amount of free and used system memory\n" | ||
60 | #endif | ||
61 | ); | ||
62 | } | ||
63 | |||
64 | 64 | ||
65 | printf("%6s%13s%13s%13s%13s%13s\n", "", "total", "used", "free", | 65 | printf("%6s%13s%13s%13s%13s%13s\n", "", "total", "used", "free", |
66 | "shared", "buffers"); | 66 | "shared", "buffers"); |