summaryrefslogtreecommitdiff
path: root/t/helper
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2017-11-06 13:11:24 +0900
committerLibravatar Junio C Hamano <gitster@pobox.com>2017-11-06 13:11:24 +0900
commita823e3a7fc75c25677d7d6eaa9defc089412ff0e (patch)
treeed3aea71a27fe2723467d4349b582ade991609c6 /t/helper
parentMerge branch 'sb/diff-color-moved-use-xdl-recmatch' (diff)
parentworktree: handle broken symrefs in find_shared_symref() (diff)
downloadtgif-a823e3a7fc75c25677d7d6eaa9defc089412ff0e.tar.xz
Merge branch 'jk/misc-resolve-ref-unsafe-fixes'
Some codepaths did not check for errors when asking what branch the HEAD points at, which have been fixed. * jk/misc-resolve-ref-unsafe-fixes: worktree: handle broken symrefs in find_shared_symref() log: handle broken HEAD in decoration check remote: handle broken symrefs test-ref-store: avoid passing NULL to printf
Diffstat (limited to 't/helper')
-rw-r--r--t/helper/test-ref-store.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/helper/test-ref-store.c b/t/helper/test-ref-store.c
index 05d8c4d8af..6ec2670044 100644
--- a/t/helper/test-ref-store.c
+++ b/t/helper/test-ref-store.c
@@ -135,7 +135,7 @@ static int cmd_resolve_ref(struct ref_store *refs, const char **argv)
ref = refs_resolve_ref_unsafe(refs, refname, resolve_flags,
sha1, &flags);
- printf("%s %s 0x%x\n", sha1_to_hex(sha1), ref, flags);
+ printf("%s %s 0x%x\n", sha1_to_hex(sha1), ref ? ref : "(null)", flags);
return ref ? 0 : 1;
}