summaryrefslogtreecommitdiff
path: root/builtin/fetch.c
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2020-09-22 12:36:34 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2020-09-22 12:36:34 -0700
commit6854689e65700b361eb5d7ff3d4af01bd3e650fe (patch)
tree8f449a1965a1913f0771b0bca5dc92a82b43ff53 /builtin/fetch.c
parentMerge branch 'dl/complete-format-patch-recent-features' (diff)
parentfetch: pass --ipv4 and --ipv6 options to sub-fetches (diff)
downloadtgif-6854689e65700b361eb5d7ff3d4af01bd3e650fe.tar.xz
Merge branch 'ar/fetch-ipversion-in-all'
"git fetch --all --ipv4/--ipv6" forgot to pass the protocol options to instances of the "git fetch" that talk to individual remotes, which has been corrected. * ar/fetch-ipversion-in-all: fetch: pass --ipv4 and --ipv6 options to sub-fetches
Diffstat (limited to 'builtin/fetch.c')
-rw-r--r--builtin/fetch.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/builtin/fetch.c b/builtin/fetch.c
index 76a4d14f57..1b00c2bee9 100644
--- a/builtin/fetch.c
+++ b/builtin/fetch.c
@@ -1552,7 +1552,10 @@ static void add_options_to_argv(struct strvec *argv)
strvec_push(argv, "-v");
else if (verbosity < 0)
strvec_push(argv, "-q");
-
+ if (family == TRANSPORT_FAMILY_IPV4)
+ strvec_push(argv, "--ipv4");
+ else if (family == TRANSPORT_FAMILY_IPV6)
+ strvec_push(argv, "--ipv6");
}
/* Fetch multiple remotes in parallel */