MCPcopy Index your code
hub / github.com/git/git / do_diff_cache

Function do_diff_cache

diff-lib.c:657–672  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

655}
656
657int do_diff_cache(const struct object_id *tree_oid, struct diff_options *opt)
658{
659 struct rev_info revs;
660
661 repo_init_revisions(opt->repo, &revs, NULL);
662 copy_pathspec(&revs.prune_data, &opt->pathspec);
663 diff_free(&revs.diffopt);
664 revs.diffopt = *opt;
665 revs.diffopt.no_free = 1;
666
667 if (diff_cache(&revs, tree_oid, NULL, 1))
668 exit(128);
669
670 release_revisions(&revs);
671 return 0;
672}
673
674int index_differs_from(struct repository *r,
675 const char *def, const struct diff_flags *flags,

Callers 8

find_originFunction · 0.85
find_renameFunction · 0.85
find_copy_in_parentFunction · 0.85
run_revertFunction · 0.85
repo_index_has_changesFunction · 0.85
diff_include_untrackedFunction · 0.85
read_from_treeFunction · 0.85

Calls 5

repo_init_revisionsFunction · 0.85
copy_pathspecFunction · 0.85
diff_freeFunction · 0.85
diff_cacheFunction · 0.85
release_revisionsFunction · 0.85

Tested by

no test coverage detected