Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2023-04-06 23:38:32 +0300
committerJunio C Hamano <gitster@pobox.com>2023-04-06 23:38:32 +0300
commit89833fc249189d5b91509b1b3f16b26aade9e7f7 (patch)
tree903a1a2e754e023eb2ad8ccdff2d8b6b75a91846 /bundle-uri.c
parentc5305bbe322edfadd746c162f8af090a227019b7 (diff)
parent25bccb4b79dce1d5c259228ef3c91eadcd13d8ac (diff)
Merge branch 'ds/fetch-bundle-uri-with-all'
"git fetch --all" does not have to download and handle the same bundleURI over and over, which has been corrected. * ds/fetch-bundle-uri-with-all: fetch: download bundles once, even with --all
Diffstat (limited to 'bundle-uri.c')
-rw-r--r--bundle-uri.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/bundle-uri.c b/bundle-uri.c
index 1ff1cf51da..e2b267cc02 100644
--- a/bundle-uri.c
+++ b/bundle-uri.c
@@ -794,6 +794,15 @@ int fetch_bundle_uri(struct repository *r, const char *uri,
init_bundle_list(&list);
+ /*
+ * Do not fetch a NULL or empty bundle URI. An empty bundle URI
+ * could signal that a configured bundle URI has been disabled.
+ */
+ if (!uri || !*uri) {
+ result = 0;
+ goto cleanup;
+ }
+
/* If a bundle is added to this global list, then it is required. */
list.mode = BUNDLE_MODE_ALL;