summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 9c2e7c0)
raw | patch | inline | side by side (parent: 9c2e7c0)
author | Junio C Hamano <junkio@cox.net> | |
Tue, 6 Dec 2005 06:29:36 +0000 (22:29 -0800) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Tue, 6 Dec 2005 06:29:36 +0000 (22:29 -0800) |
"git-init-db junk" does not complain but just ignores "junk".
Die with the usage string in such a case.
Signed-off-by: Junio C Hamano <junkio@cox.net>
Die with the usage string in such a case.
Signed-off-by: Junio C Hamano <junkio@cox.net>
init-db.c | patch | blob | history |
diff --git a/init-db.c b/init-db.c
index 8195b6842ea4eb1f6e3e0d72f8c5900b4d7e2a8a..ead37b5ed86e5ae96c18d081fbfffd65ed74dce8 100644 (file)
--- a/init-db.c
+++ b/init-db.c
for (i = 1; i < argc; i++, argv++) {
char *arg = argv[1];
- if (arg[0] != '-')
- break;
- else if (!strncmp(arg, "--template=", 11))
+ if (!strncmp(arg, "--template=", 11))
template_dir = arg+11;
else
die(init_db_usage);