summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 498a6e7)
raw | patch | inline | side by side (parent: 498a6e7)
author | Christian Couder <chriscool@tuxfamily.org> | |
Sat, 26 Apr 2008 13:19:29 +0000 (15:19 +0200) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Sun, 27 Apr 2008 20:19:46 +0000 (13:19 -0700) |
Before this patch something like:
$ git rev-parse --verify <good-rev> <junk>
worked whatever junk was as long as <good-rev> could be parsed
correctly.
This patch makes "git rev-parse --verify" error out when passed
any junk after a good rev.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
$ git rev-parse --verify <good-rev> <junk>
worked whatever junk was as long as <good-rev> could be parsed
correctly.
This patch makes "git rev-parse --verify" error out when passed
any junk after a good rev.
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-rev-parse.c | patch | blob | history |
diff --git a/builtin-rev-parse.c b/builtin-rev-parse.c
index 9384a991eec9e1d1d9395caf4a72d6babb288e89..0e597073239c97160582fbb7047794796f67987f 100644 (file)
--- a/builtin-rev-parse.c
+++ b/builtin-rev-parse.c
show_rev(REVERSED, sha1, arg+1);
continue;
}
+ if (verify)
+ die_no_single_rev(quiet);
as_is = 1;
if (!show_file(arg))
continue;
- if (verify)
- die_no_single_rev(quiet);
verify_filename(prefix, arg);
}
show_default();