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

Function store_selected

pack-bitmap-write.c:896–913  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

894}
895
896static void store_selected(struct bitmap_writer *writer,
897 struct bb_commit *ent, struct commit *commit)
898{
899 struct bitmapped_commit *stored = &writer->selected[ent->idx];
900 khiter_t hash_pos;
901
902 stored->bitmap = bitmap_to_ewah(ent->bitmap);
903
904 if (ent->pseudo_merge)
905 return;
906
907 hash_pos = kh_get_oid_map(writer->bitmaps, commit->object.oid);
908 if (hash_pos == kh_end(writer->bitmaps))
909 die(_("attempted to store non-selected commit: '%s'"),
910 oid_to_hex(&commit->object.oid));
911
912 kh_value(writer->bitmaps, hash_pos) = stored;
913}
914
915int bitmap_writer_build(struct bitmap_writer *writer)
916{

Callers 1

bitmap_writer_buildFunction · 0.85

Calls 3

bitmap_to_ewahFunction · 0.85
oid_to_hexFunction · 0.85
dieFunction · 0.70

Tested by

no test coverage detected