aboutgitcodebugslistschat
diff options
context:
space:
mode:
authorLaine Stump <laine@redhat.com>2023-02-15 03:24:36 -0500
committerStefano Brivio <sbrivio@redhat.com>2023-02-16 17:32:24 +0100
commita1ab1ca2eedbc16139cf03df06c6012b22f1f2cb (patch)
treec1cf612a73bef2688cd62cec8e49b01844421ec5
parent60bd93e91f8bfb918f60f2427e16bb76301cea0d (diff)
downloadpasst-a1ab1ca2eedbc16139cf03df06c6012b22f1f2cb.tar
passt-a1ab1ca2eedbc16139cf03df06c6012b22f1f2cb.tar.gz
passt-a1ab1ca2eedbc16139cf03df06c6012b22f1f2cb.tar.bz2
passt-a1ab1ca2eedbc16139cf03df06c6012b22f1f2cb.tar.lz
passt-a1ab1ca2eedbc16139cf03df06c6012b22f1f2cb.tar.xz
passt-a1ab1ca2eedbc16139cf03df06c6012b22f1f2cb.tar.zst
passt-a1ab1ca2eedbc16139cf03df06c6012b22f1f2cb.zip
log a detailed error (not usage()) when there are extra non-option arguments
Signed-off-by: Laine Stump <laine@redhat.com> Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
-rw-r--r--conf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/conf.c b/conf.c
index d020b4f..f175405 100644
--- a/conf.c
+++ b/conf.c
@@ -1536,7 +1536,7 @@ void conf(struct ctx *c, int argc, char **argv)
if (c->mode == MODE_PASTA)
conf_pasta_ns(&netns_only, userns, netns, optind, argc, argv);
else if (optind != argc)
- usage(argv[0]);
+ die("Extra non-option argument: %s", argv[optind]);
isolate_user(uid, gid, !netns_only, userns, c->mode);