Merge branch 'tb/fix-midx-rename-while-mapped'
commitd54fd59d848422989268088c8fba01a5c27e8dc2
authorJunio C Hamano <gitster@pobox.com>
Mon, 25 Oct 2021 23:07:00 +0000 (25 16:07 -0700)
committerJunio C Hamano <gitster@pobox.com>
Mon, 25 Oct 2021 23:07:00 +0000 (25 16:07 -0700)
tree3cd38038e64bcb450e78e0e4ee78cf402b76d936
parent67f310e1adfe3cc186aa3dd5c1acfc94398540cc
parentae22e8415d5ec2b52a4c83e181297ac15aeaced0
Merge branch 'tb/fix-midx-rename-while-mapped'

The codepath to write a new version of .midx multi-pack index files
has learned to release the mmaped memory holding the current
version of .midx before removing them from the disk, as some
platforms do not allow removal of a file that still has mapping.

* tb/fix-midx-rename-while-mapped:
  midx.c: guard against commit_lock_file() failures
  midx.c: lookup MIDX by object directory during repack
  midx.c: lookup MIDX by object directory during expire
  midx.c: extract MIDX lookup by object_dir