diff options
| author | Junio C Hamano <gitster@pobox.com> | 2014-12-22 12:26:50 -0800 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2014-12-22 12:26:50 -0800 |
| commit | a7ddaa8eacb45fdd5241e52d72e6f75d8b67b953 (patch) | |
| tree | 40b4313c9f7eb267405cef8d7f7c925e43e10509 /remote.c | |
| parent | 8e606f97f8dee35f839b50900db8ab98fe189b3c (diff) | |
| parent | 3383e199847485fedf83d0fa38bbd5363074093a (diff) | |
| download | git-a7ddaa8eacb45fdd5241e52d72e6f75d8b67b953.tar.gz | |
Merge branch 'mh/simplify-repack-without-refs'
"git remote update --prune" to drop many refs has been optimized.
* mh/simplify-repack-without-refs:
sort_string_list(): rename to string_list_sort()
prune_remote(): iterate using for_each_string_list_item()
prune_remote(): rename local variable
repack_without_refs(): make the refnames argument a string_list
prune_remote(): sort delete_refs_list references en masse
prune_remote(): initialize both delete_refs lists in a single loop
prune_remote(): exit early if there are no stale references
Diffstat (limited to 'remote.c')
| -rw-r--r-- | remote.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -1356,7 +1356,7 @@ static void add_missing_tags(struct ref *src, struct ref **dst, struct ref ***ds } clear_commit_marks_many(sent_tips.nr, sent_tips.tip, TMP_MARK); - sort_string_list(&dst_tag); + string_list_sort(&dst_tag); /* Collect tags they do not have. */ for (ref = src; ref; ref = ref->next) { @@ -1421,7 +1421,7 @@ static void prepare_ref_index(struct string_list *ref_index, struct ref *ref) for ( ; ref; ref = ref->next) string_list_append_nodup(ref_index, ref->name)->util = ref; - sort_string_list(ref_index); + string_list_sort(ref_index); } /* @@ -2135,7 +2135,7 @@ struct ref *get_stale_heads(struct refspec *refs, int ref_count, struct ref *fet info.ref_count = ref_count; for (ref = fetch_map; ref; ref = ref->next) string_list_append(&ref_names, ref->name); - sort_string_list(&ref_names); + string_list_sort(&ref_names); for_each_ref(get_stale_heads_cb, &info); string_list_clear(&ref_names, 0); return stale_refs; |
