diff options
author | Brandon Williams <bmwill@google.com> | 2018-03-15 10:31:28 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-03-15 12:01:08 -0700 |
commit | 685fbd32916f3e94bc89aa14e8fdce835b06f801 (patch) | |
tree | 679bcd54162edebd9c4f73aafa052888e63d7895 /transport.c | |
parent | 3145ea957d2ca6ba7afb087c9ed680e08d705690 (diff) | |
download | git-685fbd32916f3e94bc89aa14e8fdce835b06f801.tar.gz |
fetch-pack: perform a fetch using v2
When communicating with a v2 server, perform a fetch by requesting the
'fetch' command.
Signed-off-by: Brandon Williams <bmwill@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'transport.c')
-rw-r--r-- | transport.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/transport.c b/transport.c index 57bdbb59bc..9152a45b38 100644 --- a/transport.c +++ b/transport.c @@ -258,14 +258,17 @@ static int fetch_refs_via_pack(struct transport *transport, switch (data->version) { case protocol_v2: - die("support for protocol v2 not implemented yet"); + refs = fetch_pack(&args, data->fd, data->conn, + refs_tmp ? refs_tmp : transport->remote_refs, + dest, to_fetch, nr_heads, &data->shallow, + &transport->pack_lockfile, data->version); break; case protocol_v1: case protocol_v0: refs = fetch_pack(&args, data->fd, data->conn, refs_tmp ? refs_tmp : transport->remote_refs, dest, to_fetch, nr_heads, &data->shallow, - &transport->pack_lockfile); + &transport->pack_lockfile, data->version); break; case protocol_unknown_version: BUG("unknown protocol version"); |