]> git.tuebingen.mpg.de Git - dss.git/blobdiff - dss.c
Get rid of E_INVALID_COMMAND.
[dss.git] / dss.c
diff --git a/dss.c b/dss.c
index f33ce8d2b194178e148141133aef45c2d49d6754..665185f6f02e2e85b96c315cb9f274fab0aa0709 100644 (file)
--- a/dss.c
+++ b/dss.c
@@ -43,7 +43,8 @@ COMMANDS
 int call_command_handler(int argc, char * const * const argv)
 {
        COMMANDS
-       return -E_INVALID_COMMAND;
+       DSS_EMERG_LOG("BUG: did not find command handler\n");
+       exit(EXIT_FAILURE);
 }
 #undef COMMAND
 #undef COMMANDS
@@ -691,9 +692,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();