summaryrefslogtreecommitdiff
path: root/builtin/rev-parse.c
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2012-07-11 12:45:49 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2012-07-11 12:45:49 -0700
commit9ca724933a8d50633699acf3e5731fa392e2ff36 (patch)
tree3aacdf358feb1e0bf564b8e0a62c31b8231c8d8e /builtin/rev-parse.c
parentMerge branch 'cn/cherry-pick-range-docs' into maint (diff)
parentverify_filename(): ask the caller to chose the kind of diagnosis (diff)
downloadtgif-9ca724933a8d50633699acf3e5731fa392e2ff36.tar.xz
Merge branch 'mm/verify-filename-fix' into maint
"git diff COPYING HEAD:COPYING" gave a nonsense error message that claimed that the treeish HEAD did not have COPYING in it. * mm/verify-filename-fix: verify_filename(): ask the caller to chose the kind of diagnosis sha1_name: do not trigger detailed diagnosis for file arguments
Diffstat (limited to 'builtin/rev-parse.c')
-rw-r--r--builtin/rev-parse.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/builtin/rev-parse.c b/builtin/rev-parse.c
index 733f626f6c..13495b88f5 100644
--- a/builtin/rev-parse.c
+++ b/builtin/rev-parse.c
@@ -486,7 +486,7 @@ int cmd_rev_parse(int argc, const char **argv, const char *prefix)
if (as_is) {
if (show_file(arg) && as_is < 2)
- verify_filename(prefix, arg);
+ verify_filename(prefix, arg, 0);
continue;
}
if (!strcmp(arg,"-n")) {
@@ -734,7 +734,7 @@ int cmd_rev_parse(int argc, const char **argv, const char *prefix)
as_is = 1;
if (!show_file(arg))
continue;
- verify_filename(prefix, arg);
+ verify_filename(prefix, arg, 1);
}
if (verify) {
if (revs_count == 1) {