aboutsummaryrefslogtreecommitdiffstats
path: root/src/etc-cleanup/main.c
diff options
context:
space:
mode:
authorLibravatar Kelvin M. Klann <kmk3.code@protonmail.com>2023-05-11 18:51:02 -0300
committerLibravatar Kelvin M. Klann <kmk3.code@protonmail.com>2023-05-14 16:52:49 -0300
commit15ad8696c7cf95059f163b4f7ed86ca697e8fe1e (patch)
tree7d61eb67b0ee8118d653917fb50f446d8e6c4f9d /src/etc-cleanup/main.c
parentStandardize usage string var declarations (diff)
downloadfirejail-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/etc-cleanup/main.c')
-rw-r--r--src/etc-cleanup/main.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/etc-cleanup/main.c b/src/etc-cleanup/main.c
index 6c7bea6d6..f15ba53cd 100644
--- a/src/etc-cleanup/main.c
+++ b/src/etc-cleanup/main.c
@@ -212,13 +212,16 @@ static void process_file(const char *fname) {
212 } 212 }
213} 213}
214 214
215static const char *const usage_str =
216 "usage: cleanup-etc [options] file.profile [file.profile]\n"
217 "Group and clean private-etc entries in one or more profile files.\n"
218 "Options:\n"
219 " --debug - print debug messages\n"
220 " -h, -?, --help - this help screen\n"
221 " --replace - replace profile file\n";
222
215static void usage(void) { 223static void usage(void) {
216 printf("usage: cleanup-etc [options] file.profile [file.profile]\n"); 224 puts(usage_str);
217 printf("Group and clean private-etc entries in one or more profile files.\n");
218 printf("Options:\n");
219 printf(" --debug - print debug messages\n");
220 printf(" -h, -?, --help - this help screen\n");
221 printf(" --replace - replace profile file\n");
222} 225}
223 226
224int main(int argc, char **argv) { 227int main(int argc, char **argv) {