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

Function interpret_target

walker.c:213–227  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

211}
212
213static int interpret_target(struct walker *walker, char *target, struct object_id *oid)
214{
215 if (!get_oid_hex(target, oid))
216 return 0;
217 if (!check_refname_format(target, 0)) {
218 struct ref *ref = alloc_ref(target);
219 if (!walker->fetch_ref(walker, ref)) {
220 oidcpy(oid, &ref->old_oid);
221 free(ref);
222 return 0;
223 }
224 free(ref);
225 }
226 return -1;
227}
228
229static int mark_complete(const struct reference *ref, void *cb_data UNUSED)
230{

Callers 1

walker_fetchFunction · 0.85

Calls 4

get_oid_hexFunction · 0.85
check_refname_formatFunction · 0.85
alloc_refFunction · 0.85
oidcpyFunction · 0.85

Tested by

no test coverage detected