MCPcopy Create free account
hub / github.com/git/git / diff_filespec_size

Function diff_filespec_size

diff.c:698–709  ·  view source on GitHub ↗

like fill_mmfile, but only for size, so we can avoid retrieving blob */

Source from the content-addressed store, hash-verified

696
697/* like fill_mmfile, but only for size, so we can avoid retrieving blob */
698static unsigned long diff_filespec_size(struct repository *r,
699 struct diff_filespec *one)
700{
701 struct diff_populate_filespec_options dpf_options = {
702 .check_size_only = 1,
703 };
704
705 if (!DIFF_FILE_VALID(one))
706 return 0;
707 diff_populate_filespec(r, one, &dpf_options);
708 return one->size;
709}
710
711static int count_trailing_blank(mmfile_t *mf)
712{

Callers 1

builtin_diffstatFunction · 0.85

Calls 1

diff_populate_filespecFunction · 0.85

Tested by

no test coverage detected