aboutsummaryrefslogtreecommitdiffstats
path: root/transport-helper.c
diff options
context:
space:
mode:
authorBrandon Williams <bmwill@google.com>2018-05-16 15:58:11 -0700
committerJunio C Hamano <gitster@pobox.com>2018-05-18 06:19:43 +0900
commitd000414e26654f6f13526e4b83c648d7119586f0 (patch)
tree4562ac589c3c0121f1d1f815a8ae2c5d4e352503 /transport-helper.c
parenta2ac50cbfd232b5739bafaf6bfdb80c13633b732 (diff)
downloadgit-d000414e26654f6f13526e4b83c648d7119586f0.tar.gz
remote: convert apply_refspecs to take a struct refspec
Convert 'apply_refspecs()' to take a 'struct refspec' as a parameter instead of a list of 'struct refspec_item'. Signed-off-by: Brandon Williams <bmwill@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'transport-helper.c')
-rw-r--r--transport-helper.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/transport-helper.c b/transport-helper.c
index 33f51ebfc0..1f8ff7e942 100644
--- a/transport-helper.c
+++ b/transport-helper.c
@@ -523,7 +523,7 @@ static int fetch_with_import(struct transport *transport,
continue;
name = posn->symref ? posn->symref : posn->name;
if (data->rs.nr)
- private = apply_refspecs(data->rs.items, data->rs.nr, name);
+ private = apply_refspecs(&data->rs, name);
else
private = xstrdup(name);
if (private) {
@@ -805,7 +805,7 @@ static int push_update_refs_status(struct helper_data *data,
continue;
/* propagate back the update to the remote namespace */
- private = apply_refspecs(data->rs.items, data->rs.nr, ref->name);
+ private = apply_refspecs(&data->rs, ref->name);
if (!private)
continue;
update_ref("update by helper", private, &ref->new_oid, NULL,
@@ -942,7 +942,7 @@ static int push_refs_with_export(struct transport *transport,
char *private;
struct object_id oid;
- private = apply_refspecs(data->rs.items, data->rs.nr, ref->name);
+ private = apply_refspecs(&data->rs, ref->name);
if (private && !get_oid(private, &oid)) {
strbuf_addf(&buf, "^%s", private);
string_list_append_nodup(&revlist_args,