MCPcopy Create free account
hub / github.com/git/git / paths_collide

Function paths_collide

dir.c:142–152  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

140}
141
142int paths_collide(const char *a, const char *b)
143{
144 size_t len_a = strlen(a), len_b = strlen(b);
145
146 if (len_a == len_b)
147 return fspatheq(a, b);
148
149 if (len_a < len_b)
150 return is_dir_sep(b[len_a]) && !fspathncmp(a, b, len_a);
151 return is_dir_sep(a[len_b]) && !fspathncmp(a, b, len_b);
152}
153
154unsigned int fspathhash(const char *str)
155{

Callers 1

mark_colliding_entriesFunction · 0.85

Calls 1

fspatheqFunction · 0.85

Tested by

no test coverage detected