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

Function parse_tag

tag.c:206–227  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

204}
205
206int parse_tag(struct repository *r, struct tag *item)
207{
208 enum object_type type;
209 void *data;
210 size_t size;
211 int ret;
212
213 if (item->object.parsed)
214 return 0;
215 data = odb_read_object(r->objects, &item->object.oid, &type, &size);
216 if (!data)
217 return error("Could not read %s",
218 oid_to_hex(&item->object.oid));
219 if (type != OBJ_TAG) {
220 free(data);
221 return error("Object %s not a tag",
222 oid_to_hex(&item->object.oid));
223 }
224 ret = parse_tag_buffer(r, item, data, size);
225 free(data);
226 return ret;
227}
228
229struct object_id *get_tagged_oid(struct tag *tag)
230{

Callers 7

match_points_atFunction · 0.85
fsck_walk_tagFunction · 0.85
show_ambiguous_objectFunction · 0.85
process_tagFunction · 0.85
replace_nameFunction · 0.85
append_nameFunction · 0.85
add_tag_chainFunction · 0.85

Calls 4

odb_read_objectFunction · 0.85
errorFunction · 0.85
oid_to_hexFunction · 0.85
parse_tag_bufferFunction · 0.85

Tested by

no test coverage detected