Get rid of E_INVALID_COMMAND.
authorAndre Noll <maan@systemlinux.org>
Sun, 16 Mar 2008 16:07:26 +0000 (17:07 +0100)
committerAndre Noll <maan@systemlinux.org>
Sun, 16 Mar 2008 16:07:26 +0000 (17:07 +0100)
dss.c
error.h

diff --git a/dss.c b/dss.c
index 121cee4c8846269a084c0a7f99bac6c0cd8c04d2..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
diff --git a/error.h b/error.h
index b9cbfec373e060059d8c65ed7be5b5751527853c..d54845d0253cda4cf609c2db1a8c52634ca5fa5a 100644 (file)
--- a/error.h
+++ b/error.h
@@ -54,7 +54,6 @@ static inline void log_err_msg(int loglevel, int num)
 #define DSS_ERRORS \
        DSS_ERROR(SUCCESS, "success") \
        DSS_ERROR(SYNTAX, "syntax error") \
-       DSS_ERROR(INVALID_COMMAND, "invalid command") \
        DSS_ERROR(ATOI_OVERFLOW, "value too large") \
        DSS_ERROR(STRTOLL, "unknown strtoll error") \
        DSS_ERROR(ATOI_NO_DIGITS, "no digits found in string") \