diff options
author | 2023-05-11 18:51:02 -0300 | |
---|---|---|
committer | 2023-05-14 16:52:49 -0300 | |
commit | 15ad8696c7cf95059f163b4f7ed86ca697e8fe1e (patch) | |
tree | 7d61eb67b0ee8118d653917fb50f446d8e6c4f9d /src/fldd/main.c | |
parent | Standardize usage string var declarations (diff) | |
download | firejail-15ad8696c7cf95059f163b4f7ed86ca697e8fe1e.tar.gz firejail-15ad8696c7cf95059f163b4f7ed86ca697e8fe1e.tar.zst firejail-15ad8696c7cf95059f163b4f7ed86ca697e8fe1e.zip |
Move usage text into usage_str var
For consistency and readability.
Note: This also makes exactly one extra blank line be printed at the end
of every usage text, which is currently only done in the following
files:
* src/fcopy/main.c
* src/fnettrace-dns/main.c
* src/fnettrace-icmp/main.c
* src/fnettrace-sni/main.c
* src/fnettrace/main.c
* src/profstats/main.c
Diffstat (limited to 'src/fldd/main.c')
-rw-r--r-- | src/fldd/main.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/fldd/main.c b/src/fldd/main.c index 63398ce2e..c28cad72e 100644 --- a/src/fldd/main.c +++ b/src/fldd/main.c | |||
@@ -282,12 +282,13 @@ static void walk_directory(const char *dirname) { | |||
282 | } | 282 | } |
283 | } | 283 | } |
284 | 284 | ||
285 | 285 | static const char *const usage_str = | |
286 | "Usage: fldd program_or_directory [file]\n" | ||
287 | "Print a list of libraries used by program or store it in the file.\n" | ||
288 | "Print a list of libraries used by all .so files in a directory or store it in the file.\n"; | ||
286 | 289 | ||
287 | static void usage(void) { | 290 | static void usage(void) { |
288 | printf("Usage: fldd program_or_directory [file]\n"); | 291 | puts(usage_str); |
289 | printf("Print a list of libraries used by program or store it in the file.\n"); | ||
290 | printf("Print a list of libraries used by all .so files in a directory or store it in the file.\n"); | ||
291 | } | 292 | } |
292 | 293 | ||
293 | int main(int argc, char **argv) { | 294 | int main(int argc, char **argv) { |
@@ -363,4 +364,4 @@ int main(void) { | |||
363 | printf("Sorry, private lib is disabled in this build\n"); | 364 | printf("Sorry, private lib is disabled in this build\n"); |
364 | return 0; | 365 | return 0; |
365 | } | 366 | } |
366 | #endif \ No newline at end of file | 367 | #endif |