summaryrefslogtreecommitdiff
path: root/src/tools
diff options
context:
space:
mode:
authorMichal Zidek <mzidek@redhat.com>2012-10-12 13:59:09 +0200
committerJakub Hrozek <jhrozek@redhat.com>2012-10-16 14:05:23 +0200
commit31ddfc3c183054ca17b9c9f8f03ea8151db3b5b1 (patch)
tree99af35606c97055b9b8cb1f5ea5f5903e85e40c3 /src/tools
parent4fb12db7504920d12ea7db71f312334c877bff7c (diff)
downloadsssd-31ddfc3c183054ca17b9c9f8f03ea8151db3b5b1.tar.gz
sssd-31ddfc3c183054ca17b9c9f8f03ea8151db3b5b1.tar.bz2
sssd-31ddfc3c183054ca17b9c9f8f03ea8151db3b5b1.zip
sss_debuglevel: Multiple arguments are treated as error.
https://fedorahosted.org/sssd/ticket/1327
Diffstat (limited to 'src/tools')
-rw-r--r--src/tools/sss_debuglevel.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/tools/sss_debuglevel.c b/src/tools/sss_debuglevel.c
index 74a63eb2..72701386 100644
--- a/src/tools/sss_debuglevel.c
+++ b/src/tools/sss_debuglevel.c
@@ -97,6 +97,12 @@ int main(int argc, const char **argv)
ret, fini);
}
+ /* No more arguments expected. If something follows it is an error. */
+ if (poptGetArg(pc)) {
+ BAD_POPT_PARAMS(pc, _("Only one argument expected\n"),
+ ret, fini);
+ }
+
/* get config file */
if (pc_config_file) {
config_file = talloc_strdup(ctx, pc_config_file);