diff options
author | Jakob Kaivo <jkk@ung.org> | 2020-01-14 16:28:36 -0500 |
---|---|---|
committer | Jakob Kaivo <jkk@ung.org> | 2020-01-14 16:28:36 -0500 |
commit | b533431c665381fe178dc8c339c3ef72d9d087c9 (patch) | |
tree | feca0221b56276b56f9b30be95ce7315532c5910 | |
parent | 56205b5b24cff2f3404bee815a2c8a336b152c1d (diff) |
display an error if too many directories are specified
-rw-r--r-- | maje.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -24,6 +24,11 @@ int main(int argc, char *argv[]) } } + if (optind < argc - 1) { + fprintf(stderr, "maje: extra operands\n"); + return 1; + } + srcdir = argv[optind]; if (srcdir == NULL) { |