src-port-pgcheckdir.c.patch
application/octet-stream
Filename: src-port-pgcheckdir.c.patch
Type: application/octet-stream
Part: 0
Patch
Format: unified
| File | + | − |
|---|---|---|
| src/port/pgcheckdir.c | 1 | 2 |
diff --git a/src/port/pgcheckdir.c b/src/port/pgcheckdir.c
index 3b8258c..63b68af 100644
--- a/src/port/pgcheckdir.c
+++ b/src/port/pgcheckdir.c
@@ -41,8 +41,7 @@ pg_check_dir(const char *dir)
while ((file = readdir(chkdir)) != NULL)
{
- if (strcmp(".", file->d_name) == 0 ||
- strcmp("..", file->d_name) == 0)
+ if (file->d_name[0] == '.' && file->d_type == DT_DIR)
{
/* skip this and parent directory */
continue;