Skip to content

Commit 7dabd05

Browse files
mhaggergitster
authored andcommitted
find_symref(): rewrite to take an object_id argument
Signed-off-by: Michael Haggerty <[email protected]> Signed-off-by: brian m. carlson <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 1700cb3 commit 7dabd05

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

upload-pack.c

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -741,8 +741,8 @@ static int send_ref(const char *refname, const unsigned char *sha1, int flag, vo
741741
return 0;
742742
}
743743

744-
static int find_symref(const char *refname, const unsigned char *sha1, int flag,
745-
void *cb_data)
744+
static int find_symref(const char *refname, const struct object_id *oid,
745+
int flag, void *cb_data)
746746
{
747747
const char *symref_target;
748748
struct string_list_item *item;
@@ -761,10 +761,8 @@ static int find_symref(const char *refname, const unsigned char *sha1, int flag,
761761
static void upload_pack(void)
762762
{
763763
struct string_list symref = STRING_LIST_INIT_DUP;
764-
struct each_ref_fn_sha1_adapter wrapped_find_symref =
765-
{find_symref, &symref};
766764

767-
head_ref_namespaced(each_ref_fn_adapter, &wrapped_find_symref);
765+
head_ref_namespaced(find_symref, &symref);
768766

769767
if (advertise_refs || !stateless_rpc) {
770768
struct each_ref_fn_sha1_adapter wrapped_send_ref =

0 commit comments

Comments
 (0)