diff options
-rw-r--r-- | xfd.c | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -194,6 +194,15 @@ main(int argc, char *argv[]) xfd_options, XtNumber(xfd_options), &argc, argv, NULL, NULL, 0); + if (argc != 1) { + fputs("Unknown argument(s):", stderr); + for (int n = 1; n < argc; n++) { + fprintf(stderr, " %s", argv[n]); + } + fputs("\n\n", stderr); + usage (); + } + #ifdef USE_GETTEXT { const char *domaindir; @@ -214,7 +223,6 @@ main(int argc, char *argv[]) Resources[3].default_addr = gettext(DEF_START_FORMAT); Resources[4].default_addr = gettext(DEF_NOCHAR_FORMAT); - if (argc != 1) usage (); XtAppAddActions (xtcontext, xfd_actions, XtNumber (xfd_actions)); XtOverrideTranslations (toplevel, XtParseTranslationTable ("<Message>WM_PROTOCOLS: Quit()")); |