Merge branch 'ph/fetch-prune-optim'

"git fetch --prune" used to be O(n^2) expensive when there are many
refs, which has been corrected.

* ph/fetch-prune-optim:
  clean up interface for refs_warn_dangling_symrefs
  refs: remove old refs_warn_dangling_symref
  fetch-prune: optimize dangling-ref reporting
This commit is contained in:
Junio C Hamano
2025-07-16 09:42:26 -07:00
4 changed files with 23 additions and 40 deletions

5
refs.h
View File

@@ -452,10 +452,9 @@ static inline const char *has_glob_specials(const char *pattern)
return strpbrk(pattern, "?*[");
}
void refs_warn_dangling_symref(struct ref_store *refs, FILE *fp,
const char *msg_fmt, const char *refname);
void refs_warn_dangling_symrefs(struct ref_store *refs, FILE *fp,
const char *msg_fmt, const struct string_list *refnames);
const char *indent, int dry_run,
const struct string_list *refnames);
/*
* Flags for controlling behaviour of pack_refs()