[ostree] pull: Only fetch all refs if we're mirroring
- From: Colin Walters <walters src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [ostree] pull: Only fetch all refs if we're mirroring
- Date: Tue, 1 Sep 2015 12:36:58 +0000 (UTC)
commit ef563213549eca69277e2df14d8e0b1d92c7f907
Author: Colin Walters <walters verbum org>
Date: Mon Aug 31 22:54:04 2015 -0400
pull: Only fetch all refs if we're mirroring
I noticed xdg-app was looping trying to fetch 1427 refs. We
don't want to do that unless asked to.
(And also, we need to make static delta requests async)
src/libostree/ostree-repo-pull.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/libostree/ostree-repo-pull.c b/src/libostree/ostree-repo-pull.c
index 74acad5..e82340a 100644
--- a/src/libostree/ostree-repo-pull.c
+++ b/src/libostree/ostree-repo-pull.c
@@ -1932,7 +1932,8 @@ ostree_repo_pull_with_options (OstreeRepo *self,
if (!ostree_validate_rev (refname, error))
goto out;
- g_hash_table_insert (requested_refs_to_fetch, g_strdup (refname), NULL);
+ if (pull_data->is_mirror && !refs_to_fetch)
+ g_hash_table_insert (requested_refs_to_fetch, g_strdup (refname), NULL);
}
additional_metadata = g_variant_get_child_value (pull_data->summary, 1);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]