summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 730fef3)
raw | patch | inline | side by side (parent: 730fef3)
author | Benjamin Pineau <ben.pineau@gmail.com> | |
Sat, 5 Jul 2008 08:45:09 +0000 (10:45 +0200) | ||
committer | Florian Forster <octo@leeloo.lan.home.verplant.org> | |
Sat, 5 Jul 2008 08:45:09 +0000 (10:45 +0200) |
Also use PATH_MAX instead of 4096.
src/qmail.c | patch | blob | history |
diff --git a/src/qmail.c b/src/qmail.c
index 1a8e2bd9d3e83cee4c589f6d574ecd281295212d..74386c38f7624c2ba6a0edd916a2a86b94aef95e 100644 (file)
--- a/src/qmail.c
+++ b/src/qmail.c
count = 0;
while ((de = readdir (dh)) != NULL)
{
- char abs_path[4096];
+ char abs_path[PATH_MAX];
struct stat statbuf;
+ if (de->d_name[0] == '.')
+ continue;
+
ssnprintf (abs_path, sizeof (abs_path), "%s/%s", path, de->d_name);
status = lstat (abs_path, &statbuf);