midx.c: extract MIDX lookup by object_dir
commit504131ac26895d1aaa814785d455c2c7f61c4e16
authorTaylor Blau <me@ttaylorr.com>
Fri, 8 Oct 2021 21:46:29 +0000 (8 17:46 -0400)
committerJunio C Hamano <gitster@pobox.com>
Fri, 15 Oct 2021 20:08:11 +0000 (15 13:08 -0700)
tree2f02c828b2ca7d48437111fdde8aa3ba77c834b7
parent823b4281ca259788f2dc71bfd2b459a1b14e46f6
midx.c: extract MIDX lookup by object_dir

The first thing that write_midx_internal() does is load the MIDX
corresponding to the given object directory, if one is present.

Prepare for other functions in midx.c to do the same thing by extracting
that operation out to a small helper function.

Signed-off-by: Taylor Blau <me@ttaylorr.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
midx.c