From: Andre Noll Date: Sun, 16 Mar 2008 16:05:01 +0000 (+0100) Subject: dss.c: Fix check for number of non-options. X-Git-Tag: v0.0.2~8 X-Git-Url: http://git.tuebingen.mpg.de/?p=dss.git;a=commitdiff_plain;h=52917042ff1fca9f83c68ed1c38a92526e1afcb0;hp=0ff8f4b1fe02af09e36680844619323bebeb067b dss.c: Fix check for number of non-options. With group options, it's a syntax error to specify any non-options. --- diff --git a/dss.c b/dss.c index f33ce8d..121cee4 100644 --- a/dss.c +++ b/dss.c @@ -691,9 +691,9 @@ int main(int argc, char **argv) int ret; cmdline_parser(argc, argv, &conf); /* aborts on errors */ - if (!conf.inputs_num) { + if (conf.inputs_num) { ret = -E_SYNTAX; - make_err_msg("no command given"); + make_err_msg("additional non-options given"); goto out; } ret = read_config_file();