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 <bmwill@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Brandon Williams
2018-03-15 10:31:23 -07:00
committed by Junio C Hamano
parent 834cf34b26
commit 1af8ae1cfa
6 changed files with 21 additions and 8 deletions

View File

@ -96,7 +96,7 @@ int cmd_ls_remote(int argc, const char **argv, const char *prefix)
if (uploadpack != NULL)
transport_set_option(transport, TRANS_OPT_UPLOADPACK, uploadpack);
ref = transport_get_remote_refs(transport);
ref = transport_get_remote_refs(transport, NULL);
if (transport_disconnect(transport))
return 1;