Doesn't apply file filter rules to directory.

In Windows uses the information reported by FindFirstFile instead of calling lstat().
This commit is contained in:
Andrea Mazzoleni 2013-01-18 00:15:55 +01:00
parent 5171e93ee5
commit 8204dfad6a
6 changed files with 55 additions and 33 deletions

4
elem.h
View file

@ -234,9 +234,9 @@ void filter_free(struct snapraid_filter* filter);
* Filter hidden files.
* Return !=0 if it matches and it should be excluded.
*/
static inline int filter_hidden(int enable, struct dirent* dd, struct stat* st)
static inline int filter_hidden(int enable, struct dirent* dd)
{
if (enable && stat_hidden(dd, st)) {
if (enable && dirent_hidden(dd)) {
return 1; /* filter out */
}