]> git.pond.sub.org Git - empserver/commitdiff
(apro) [!_WIN32]: Silently ignore directory entries starting with '.'.
authorMarkus Armbruster <armbru@pond.sub.org>
Sat, 23 Sep 2006 15:00:01 +0000 (15:00 +0000)
committerMarkus Armbruster <armbru@pond.sub.org>
Sat, 23 Sep 2006 15:00:01 +0000 (15:00 +0000)
Before, apro() logged complaints about . and .. not being regular
files.

src/lib/commands/info.c

index ee954ff0f45cc44075c4e80a7b60cbbe1828c223..4597013c0f9393cdd74cf0ad12fa67c3f865caa7 100644 (file)
@@ -210,8 +210,10 @@ apro(void)
      */
     nf = nhf = nl = nhl = 0;
     while ((dp = readdir(info_dp)) != 0) {
+       if (dp->d_name[0] == '.')
+           continue;
        snprintf(filename, sizeof(filename), "%s/%s", infodir,
-           dp->d_name);
+                dp->d_name);
        fp = fopen(filename, "r");
        alreadyhit = 0;
        nll = nlhl = 0;