| 112 | }; |
| 113 | |
| 114 | static int remotes_hash_cmp(const void *cmp_data UNUSED, |
| 115 | const struct hashmap_entry *eptr, |
| 116 | const struct hashmap_entry *entry_or_key, |
| 117 | const void *keydata) |
| 118 | { |
| 119 | const struct remote *a, *b; |
| 120 | const struct remotes_hash_key *key = keydata; |
| 121 | |
| 122 | a = container_of(eptr, const struct remote, ent); |
| 123 | b = container_of(entry_or_key, const struct remote, ent); |
| 124 | |
| 125 | if (key) |
| 126 | return !!xstrncmpz(a->name, key->str, key->len); |
| 127 | else |
| 128 | return strcmp(a->name, b->name); |
| 129 | } |
| 130 | |
| 131 | static struct remote *make_remote(struct remote_state *remote_state, |
| 132 | const char *name, int len) |
nothing calls this directly
no test coverage detected