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

Function lookup_ref_store_map

refs.c:2304–2315  ·  view source on GitHub ↗

* Look up a ref store by name. If that ref_store hasn't been * registered yet, return NULL. */

Source from the content-addressed store, hash-verified

2302 * registered yet, return NULL.
2303 */
2304static struct ref_store *lookup_ref_store_map(struct strmap *map,
2305 const char *name)
2306{
2307 struct strmap_entry *entry;
2308
2309 if (!map->map.tablesize)
2310 /* It's initialized on demand in register_ref_store(). */
2311 return NULL;
2312
2313 entry = strmap_get_entry(map, name);
2314 return entry ? entry->value : NULL;
2315}
2316
2317/*
2318 * Create, record, and return a ref_store instance for the specified

Callers 2

get_worktree_ref_storeFunction · 0.85

Calls 1

strmap_get_entryFunction · 0.85

Tested by

no test coverage detected