X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=transport.c;h=9ad4a16c317b90770974aa5afbcf0986f4a5db91;hb=81d3fe9f4871e42ebd1af0221fa091fe5476e2f7;hp=56831c57c5cf6500714c46c63581ca98662d58c3;hpb=caf8b2fbd4b49c66aa70624eaf35ebcdc007ad6d;p=git.git diff --git a/transport.c b/transport.c index 56831c57c..9ad4a16c3 100644 --- a/transport.c +++ b/transport.c @@ -50,9 +50,7 @@ static int read_loose_refs(struct strbuf *path, int name_offset, memset (&list, 0, sizeof(list)); while ((de = readdir(dir))) { - if (de->d_name[0] == '.' && (de->d_name[1] == '\0' || - (de->d_name[1] == '.' && - de->d_name[2] == '\0'))) + if (is_dot_or_dotdot(de->d_name)) continue; ALLOC_GROW(list.entries, list.nr + 1, list.alloc); list.entries[list.nr++] = xstrdup(de->d_name);