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

Function verify_bitmap_files

pack-bitmap.c:3394–3420  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3392}
3393
3394int verify_bitmap_files(struct repository *r)
3395{
3396 struct odb_source *source;
3397 struct packed_git *p;
3398 int res = 0;
3399
3400 odb_prepare_alternates(r->objects);
3401 for (source = r->objects->sources; source; source = source->next) {
3402 struct multi_pack_index *m = get_multi_pack_index(source);
3403 char *midx_bitmap_name;
3404
3405 if (!m)
3406 continue;
3407
3408 midx_bitmap_name = midx_bitmap_filename(m);
3409 res |= verify_bitmap_file(r->hash_algo, midx_bitmap_name);
3410 free(midx_bitmap_name);
3411 }
3412
3413 repo_for_each_pack(r, p) {
3414 char *pack_bitmap_name = pack_bitmap_filename(p);
3415 res |= verify_bitmap_file(r->hash_algo, pack_bitmap_name);
3416 free(pack_bitmap_name);
3417 }
3418
3419 return res;
3420}

Callers 1

cmd_fsckFunction · 0.85

Calls 5

odb_prepare_alternatesFunction · 0.85
get_multi_pack_indexFunction · 0.85
midx_bitmap_filenameFunction · 0.85
verify_bitmap_fileFunction · 0.85
pack_bitmap_filenameFunction · 0.85

Tested by

no test coverage detected