summaryrefslogtreecommitdiff
path: root/midx-write.c
diff options
context:
space:
mode:
Diffstat (limited to 'midx-write.c')
-rw-r--r--midx-write.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/midx-write.c b/midx-write.c
index bf7c01d4b1..84f76856d6 100644
--- a/midx-write.c
+++ b/midx-write.c
@@ -981,10 +981,11 @@ static int link_midx_to_chain(struct multi_pack_index *m)
for (i = 0; i < ARRAY_SIZE(midx_exts); i++) {
const unsigned char *hash = get_midx_checksum(m);
- get_midx_filename_ext(m->repo->hash_algo, &from, m->object_dir,
+ get_midx_filename_ext(m->source->odb->repo->hash_algo, &from,
+ m->source->path,
hash, midx_exts[i].non_split);
- get_split_midx_filename_ext(m->repo->hash_algo, &to,
- m->object_dir, hash,
+ get_split_midx_filename_ext(m->source->odb->repo->hash_algo, &to,
+ m->source->path, hash,
midx_exts[i].split);
if (link(from.buf, to.buf) < 0 && errno != ENOENT) {
@@ -1109,7 +1110,7 @@ static int write_midx_internal(struct odb_source *source,
if (flags & MIDX_WRITE_BITMAP && load_midx_revindex(m)) {
error(_("could not load reverse index for MIDX %s"),
hash_to_hex_algop(get_midx_checksum(m),
- m->repo->hash_algo));
+ m->source->odb->repo->hash_algo));
result = 1;
goto cleanup;
}