summaryrefslogtreecommitdiffhomepage
path: root/main.c
diff options
context:
space:
mode:
authorPetr Štetiar <ynezz@true.cz>2021-03-19 17:06:09 +0100
committerJo-Philipp Wich <jo@mein.io>2021-04-23 00:42:30 +0200
commit80393611fb6634abcc0da1dee2da7c4418dbde8d (patch)
tree92c4589da3ced90fdc573ac07cf1e46a6684386c /main.c
parent778e4f7bf205d04d631f968e5b33cfdf9e8121e1 (diff)
main: provide just binary name in help output
Otherwise it prints out complete path which is probably not desired and we would need to filter out paths in the test's output etc. Signed-off-by: Petr Štetiar <ynezz@true.cz>
Diffstat (limited to 'main.c')
-rw-r--r--main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/main.c b/main.c
index 36d42a8..55c9dd8 100644
--- a/main.c
+++ b/main.c
@@ -36,7 +36,7 @@
static void
-print_usage(char *app)
+print_usage(const char *app)
{
printf(
"== Usage ==\n\n"
@@ -51,7 +51,7 @@ print_usage(char *app)
" -e Set global variables from given JSON object\n"
" -E Set global variables from given JSON file\n"
" -m Preload given module\n",
- app);
+ basename(app));
}
static void