make "find_ref_by_name" a public function
This was a static in remote.c, but is generally useful. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
9f8a15c734
commit
cda69f481d
8
remote.c
8
remote.c
@ -696,14 +696,6 @@ static int match_explicit_refs(struct ref *src, struct ref *dst,
|
||||
return -errs;
|
||||
}
|
||||
|
||||
static struct ref *find_ref_by_name(struct ref *list, const char *name)
|
||||
{
|
||||
for ( ; list; list = list->next)
|
||||
if (!strcmp(list->name, name))
|
||||
return list;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static const struct refspec *check_pattern_match(const struct refspec *rs,
|
||||
int rs_nr,
|
||||
const struct ref *src)
|
||||
|
||||
Reference in New Issue
Block a user