cocci: apply the "refs.h" part of "the_repository.pending"
Apply the part of "the_repository.pending.cocci" pertaining to "refs.h". Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
a5183d7696
commit
12cb1c10a6
@ -1204,7 +1204,8 @@ static char *find_branch_name(struct rev_info *rev)
|
||||
return NULL;
|
||||
ref = rev->cmdline.rev[positive].name;
|
||||
tip_oid = &rev->cmdline.rev[positive].item->oid;
|
||||
if (dwim_ref(ref, strlen(ref), &branch_oid, &full_ref, 0) &&
|
||||
if (repo_dwim_ref(the_repository, ref, strlen(ref), &branch_oid,
|
||||
&full_ref, 0) &&
|
||||
skip_prefix(full_ref, "refs/heads/", &v) &&
|
||||
oideq(tip_oid, &branch_oid))
|
||||
branch = xstrdup(v);
|
||||
|
Reference in New Issue
Block a user