diff options
-rw-r--r-- | src/apprentice.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/apprentice.c b/src/apprentice.c index 9262ff3d..04c41539 100644 --- a/src/apprentice.c +++ b/src/apprentice.c @@ -32,7 +32,7 @@ #include "file.h" #ifndef lint -FILE_RCSID("@(#)$File: apprentice.c,v 1.258 2017/02/10 18:14:01 christos Exp $") +FILE_RCSID("@(#)$File: apprentice.c,v 1.259 2017/02/17 17:34:43 christos Exp $") #endif /* lint */ #include "magic.h" @@ -1316,6 +1316,8 @@ apprentice_load(struct magic_set *ms, const char *fn, int action) goto out; } while ((d = readdir(dir)) != NULL) { + if (d->d_name[0] == '.') + continue; if (asprintf(&mfn, "%s/%s", fn, d->d_name) < 0) { file_oomem(ms, strlen(fn) + strlen(d->d_name) + 2); |