]> git.ipfire.org Git - thirdparty/git.git/blobdiff - tree-diff.c
midx: add progress indicators in multi-pack-index verify
[thirdparty/git.git] / tree-diff.c
index 553bc0e63ae37ada1c3e19ae748d1228561f00f6..e6d306f69f940edd9613de0b38ffe2d9993f91ab 100644 (file)
@@ -239,7 +239,7 @@ static struct combine_diff_path *emit_path(struct combine_diff_path *p,
                                                DIFF_STATUS_ADDED;
 
                        if (tpi_valid) {
-                               oid_i = tp[i].entry.oid;
+                               oid_i = &tp[i].entry.oid;
                                mode_i = tp[i].entry.mode;
                        }
                        else {
@@ -280,7 +280,7 @@ static struct combine_diff_path *emit_path(struct combine_diff_path *p,
                        /* same rule as in emitthis */
                        int tpi_valid = tp && !(tp[i].entry.mode & S_IFXMIN_NEQ);
 
-                       parents_oid[i] = tpi_valid ? tp[i].entry.oid : NULL;
+                       parents_oid[i] = tpi_valid ? &tp[i].entry.oid : NULL;
                }
 
                strbuf_add(base, path, pathlen);
@@ -299,7 +299,8 @@ static void skip_uninteresting(struct tree_desc *t, struct strbuf *base,
        enum interesting match;
 
        while (t->size) {
-               match = tree_entry_interesting(&t->entry, base, 0, &opt->pathspec);
+               match = tree_entry_interesting(opt->repo->index, &t->entry,
+                                              base, 0, &opt->pathspec);
                if (match) {
                        if (match == all_entries_not_interesting)
                                t->size = 0;
@@ -491,7 +492,7 @@ static struct combine_diff_path *ll_diff_tree_paths(
                                                continue;
 
                                        /* diff(t,pi) != ΓΈ */
-                                       if (oidcmp(t.entry.oid, tp[i].entry.oid) ||
+                                       if (!oideq(&t.entry.oid, &tp[i].entry.oid) ||
                                            (t.entry.mode != tp[i].entry.mode))
                                                continue;
 
@@ -605,7 +606,7 @@ static void try_to_follow_renames(const struct object_id *old_oid,
        choice = q->queue[0];
        q->nr = 0;
 
-       diff_setup(&diff_opts);
+       repo_diff_setup(opt->repo, &diff_opts);
        diff_opts.flags.recursive = 1;
        diff_opts.flags.find_copies_harder = 1;
        diff_opts.output_format = DIFF_FORMAT_NO_OUTPUT;