aboutsummaryrefslogtreecommitdiffstats
path: root/diffcore-rotate.c
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2024-09-30 11:13:35 +0200
committerJunio C Hamano <gitster@pobox.com>2024-09-30 11:23:04 -0700
commit6361dea6e8f4476b495319a9d3eeed2e2e694f8a (patch)
tree455b7eb20856e1354d138a8d48f4bea4aa82a030 /diffcore-rotate.c
parentbuiltin/pack-redundant: fix various memory leaks (diff)
downloadgit-6361dea6e8f4476b495319a9d3eeed2e2e694f8a.tar.gz
git-6361dea6e8f4476b495319a9d3eeed2e2e694f8a.zip
builtin/clone: fix leaking repo state when cloning with bundle URIs
When cloning with bundle URIs we re-initialize `the_repository` after having fetched the bundle. This causes a bunch of memory leaks though because we do not release its previous state. These leaks can be plugged by calling `repo_clear()` before we call `repo_init()`. But this causes another issue because the remote that we used is tied to the lifetime of the repository's remote state, which would also get released. We thus have to make sure that it does not get free'd under our feet. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'diffcore-rotate.c')
0 files changed, 0 insertions, 0 deletions