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

Function set_commit_pos

commit-graph.c:88–97  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

86}
87
88static void set_commit_pos(struct repository *r, const struct object_id *oid)
89{
90 static int32_t max_pos;
91 struct commit *commit = lookup_commit(r, oid);
92
93 if (!commit)
94 return; /* should never happen, but be lenient */
95
96 *commit_pos_at(&commit_pos, commit) = max_pos++;
97}
98
99static int commit_pos_cmp(const void *va, const void *vb)
100{

Callers 1

add_packed_commits_oiFunction · 0.85

Calls 1

lookup_commitFunction · 0.85

Tested by

no test coverage detected