aboutsummaryrefslogtreecommitdiff
path: root/coreutils/du.c
diff options
context:
space:
mode:
Diffstat (limited to 'coreutils/du.c')
-rw-r--r--coreutils/du.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/coreutils/du.c b/coreutils/du.c
index 702a9aa14..1c16cfbd4 100644
--- a/coreutils/du.c
+++ b/coreutils/du.c
@@ -144,10 +144,9 @@ static long du(char *filename)
while ((entry = readdir(dir))) {
char *name = entry->d_name;
- if ((name[0] == '.') && (!name[1] || (name[1] == '.' && !name[2]))) {
+ newfile = concat_subpath_file(filename, name);
+ if(newfile == NULL)
continue;
- }
- newfile = concat_path_file(filename, name);
++du_depth;
sum += du(newfile);
--du_depth;