poldek: poldek/conf.c - fixed %includedir: only readable files are included...

mis mis at pld-linux.org
Sat May 24 22:59:59 CEST 2008


Author: mis                          Date: Sat May 24 20:59:59 2008 GMT
Module: poldek                        Tag: HEAD
---- Log message:
- fixed %includedir: only readable files are included (#137)

---- Files affected:
poldek/poldek:
   conf.c (1.86 -> 1.87) 

---- Diffs:

================================================================
Index: poldek/poldek/conf.c
diff -u poldek/poldek/conf.c:1.86 poldek/poldek/conf.c:1.87
--- poldek/poldek/conf.c:1.86	Wed Jan 30 16:16:41 2008
+++ poldek/poldek/conf.c	Sat May 24 22:59:54 2008
@@ -969,7 +969,8 @@
             continue;
 
         n = n_snprintf(path, sizeof(path), "%s%s%s", dirpath, sep, ent->d_name);
-        n_array_push(configs, n_strdupl(path, n));
+        if (access(path, R_OK) == 0)
+            n_array_push(configs, n_strdupl(path, n));
     }
     closedir(dir);
     
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/poldek/poldek/conf.c?r1=1.86&r2=1.87&f=u



More information about the pld-cvs-commit mailing list