summaryrefslogtreecommitdiffstats
path: root/contrib/persistent-https
diff options
context:
space:
mode:
authorChristian Couder <christian.couder@gmail.com>2026-04-07 13:52:41 +0200
committerJunio C Hamano <gitster@pobox.com>2026-04-07 08:45:44 -0700
commite0f80d8876960442dd2645215c4fe5e1b1d80fc3 (patch)
tree2f624e9131c6cec30da4391e1d4413a40f7b4b19 /contrib/persistent-https
parent7557a562434804d27f1417fe94c4081e2ee7e68b (diff)
downloadgit-e0f80d8876960442dd2645215c4fe5e1b1d80fc3.tar.gz
git-e0f80d8876960442dd2645215c4fe5e1b1d80fc3.zip
promisor-remote: keep accepted promisor_info structs alive
In filter_promisor_remote(), the instances of `struct promisor_info` for accepted remotes are dismantled into separate parallel data structures (the 'accepted' strvec for server names, and 'accepted_filters' for filter strings) and then immediately freed. Instead, let's keep these instances on an 'accepted_remotes' list. This way the post-loop phase can iterate a single list to build the protocol reply, apply advertised filters, and mark remotes as accepted, rather than iterating three separate structures. This refactoring also prepares for a future commit that will add a 'local_name' member to 'struct promisor_info'. Since struct instances stay alive, downstream code will be able to simply read both names from them rather than needing yet another parallel strvec. Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'contrib/persistent-https')
0 files changed, 0 insertions, 0 deletions