| 268 | } |
| 269 | |
| 270 | static int ce_compare_gitlink(const struct cache_entry *ce) |
| 271 | { |
| 272 | struct object_id oid; |
| 273 | |
| 274 | /* |
| 275 | * We don't actually require that the .git directory |
| 276 | * under GITLINK directory be a valid git directory. It |
| 277 | * might even be missing (in case nobody populated that |
| 278 | * sub-project). |
| 279 | * |
| 280 | * If so, we consider it always to match. |
| 281 | */ |
| 282 | if (repo_resolve_gitlink_ref(the_repository, ce->name, |
| 283 | "HEAD", &oid) < 0) |
| 284 | return 0; |
| 285 | return !oideq(&oid, &ce->oid); |
| 286 | } |
| 287 | |
| 288 | static int ce_modified_check_fs(struct index_state *istate, |
| 289 | const struct cache_entry *ce, |
no test coverage detected