From 1af8ae1cfa44a3f3c3f1efb7f9ebe68bc0ce7578 Mon Sep 17 00:00:00 2001 From: Brandon Williams Date: Thu, 15 Mar 2018 10:31:23 -0700 Subject: transport: convert transport_get_remote_refs to take a list of ref prefixes Teach transport_get_remote_refs() to accept a list of ref prefixes, which will be sent to the server for use in filtering when using protocol v2. (This list will be ignored when not using protocol v2.) Signed-off-by: Brandon Williams Signed-off-by: Junio C Hamano --- transport.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'transport.c') diff --git a/transport.c b/transport.c index 2e68010dd0..3f130518d2 100644 --- a/transport.c +++ b/transport.c @@ -1138,10 +1138,13 @@ int transport_push(struct transport *transport, return 1; } -const struct ref *transport_get_remote_refs(struct transport *transport) +const struct ref *transport_get_remote_refs(struct transport *transport, + const struct argv_array *ref_prefixes) { if (!transport->got_remote_refs) { - transport->remote_refs = transport->vtable->get_refs_list(transport, 0, NULL); + transport->remote_refs = + transport->vtable->get_refs_list(transport, 0, + ref_prefixes); transport->got_remote_refs = 1; } -- cgit v1.2.3