| 2281 | } |
| 2282 | |
| 2283 | int repo_resolve_gitlink_ref(struct repository *r, |
| 2284 | const char *submodule, const char *refname, |
| 2285 | struct object_id *oid) |
| 2286 | { |
| 2287 | struct ref_store *refs; |
| 2288 | int flags; |
| 2289 | |
| 2290 | refs = repo_get_submodule_ref_store(r, submodule); |
| 2291 | if (!refs) |
| 2292 | return -1; |
| 2293 | |
| 2294 | if (!refs_resolve_ref_unsafe(refs, refname, 0, oid, &flags) || |
| 2295 | is_null_oid(oid)) |
| 2296 | return -1; |
| 2297 | return 0; |
| 2298 | } |
| 2299 | |
| 2300 | /* |
| 2301 | * Look up a ref store by name. If that ref_store hasn't been |
no test coverage detected