diff options
author | Erik Andersen | 2000-02-11 21:55:04 +0000 |
---|---|---|
committer | Erik Andersen | 2000-02-11 21:55:04 +0000 |
commit | 9ffdaa647ee57263247e047e6c67c5a7fa1f2a6c (patch) | |
tree | 3485e1645439990642fcb941d579deb10f8a17a7 /du.c | |
parent | 5e1b2ca1161cba481ccf4873427389f59dbc23e0 (diff) | |
download | busybox-9ffdaa647ee57263247e047e6c67c5a7fa1f2a6c.zip busybox-9ffdaa647ee57263247e047e6c67c5a7fa1f2a6c.tar.gz |
Updates
-Erik
Diffstat (limited to 'du.c')
-rw-r--r-- | du.c | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -72,6 +72,10 @@ static long du(char *filename) du_depth++; sum = statbuf.st_blocks; + /* Don't add in stuff pointed to by links */ + if (S_ISLNK(statbuf.st_mode)) { + return 0; + } if (S_ISDIR(statbuf.st_mode)) { DIR *dir; struct dirent *entry; @@ -140,7 +144,7 @@ int du_main(int argc, char **argv) for (; i < argc; i++) { sum = du(argv[i]); - if ((sum) && (isDirectory(argv[i], FALSE))) { + if ((sum) && (isDirectory(argv[i], FALSE, NULL))) { print_normal(sum, argv[i]); } } @@ -149,4 +153,4 @@ int du_main(int argc, char **argv) exit(0); } -/* $Id: du.c,v 1.11 2000/02/08 19:58:47 erik Exp $ */ +/* $Id: du.c,v 1.12 2000/02/11 21:55:04 erik Exp $ */ |