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

Function lookup_commit

commit.c:101–107  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

99}
100
101struct commit *lookup_commit(struct repository *r, const struct object_id *oid)
102{
103 struct object *obj = lookup_object(r, oid);
104 if (!obj)
105 return create_object(r, oid, alloc_commit_node(r));
106 return object_as_type(obj, OBJ_COMMIT, 0);
107}
108
109struct commit *lookup_commit_reference_by_name(const char *name)
110{

Callers 15

parse_tag_bufferFunction · 0.85
deref_without_lazy_fetchFunction · 0.85
find_commonFunction · 0.85
add_havesFunction · 0.85
process_ackFunction · 0.85
negotiate_using_fetchFunction · 0.85
find_merge_parentsFunction · 0.85
set_commit_posFunction · 0.85
insert_parent_or_dieFunction · 0.85
lookup_commit_in_graphFunction · 0.85
close_reachableFunction · 0.85
copy_oids_to_commitsFunction · 0.85

Calls 4

lookup_objectFunction · 0.85
create_objectFunction · 0.85
alloc_commit_nodeFunction · 0.85
object_as_typeFunction · 0.85

Tested by 4

bitmap_writeFunction · 0.68