aboutsummaryrefslogtreecommitdiffstats
path: root/builtin
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2024-02-12 13:16:11 -0800
committerJunio C Hamano <gitster@pobox.com>2024-02-12 13:16:11 -0800
commitb3370dd51edb7f087754f0090ab483e9d1a2161e (patch)
tree0b0156b4a20a3e8bbc408389d858eead8b5fd0b0 /builtin
parent70550a224263099c76276eaa57ac9d0b0c724a99 (diff)
parent1af410d455c5cddae1cdea3e5333ffd6ab616045 (diff)
downloadgit-b3370dd51edb7f087754f0090ab483e9d1a2161e.tar.gz
Merge branch 'pw/show-ref-pseudorefs'
"git show-ref --verify" did not show things like "CHERRY_PICK_HEAD", which has been corrected. * pw/show-ref-pseudorefs: t1400: use show-ref to check pseudorefs show-ref --verify: accept pseudorefs
Diffstat (limited to 'builtin')
-rw-r--r--builtin/show-ref.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/show-ref.c b/builtin/show-ref.c
index 79955c2856..1c15421e60 100644
--- a/builtin/show-ref.c
+++ b/builtin/show-ref.c
@@ -172,7 +172,7 @@ static int cmd_show_ref__verify(const struct show_one_options *show_one_opts,
while (*refs) {
struct object_id oid;
- if ((starts_with(*refs, "refs/") || !strcmp(*refs, "HEAD")) &&
+ if ((starts_with(*refs, "refs/") || refname_is_safe(*refs)) &&
!read_ref(*refs, &oid)) {
show_one(show_one_opts, *refs, &oid);
}