summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/common/core.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/common/core.c b/src/common/core.c
index 74c63a6d6..9a131d042 100644
--- a/src/common/core.c
+++ b/src/common/core.c
@@ -404,6 +404,8 @@ int cmdline_exec(int argc, char **argv, unsigned int options)
struct CmdlineArgData *data = NULL;
const char *arg = argv[i];
if (arg[0] != '-') { // All arguments must begin with '-'
+ if ((options&(CMDLINE_OPT_SILENT|CMDLINE_OPT_PREINIT)) != 0)
+ continue;
ShowError("Invalid option '%s'.\n", argv[i]);
exit(EXIT_FAILURE);
}