diff options
author | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2000-12-11 17:08:21 +0000 |
---|---|---|
committer | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2000-12-11 17:08:21 +0000 |
commit | 1f4d1afe2ce4432d9a5082be1e7d5e9d4629b172 (patch) | |
tree | cf81b216a097ceac50f9c73fa9ea9a1811c6bc2e /du.c | |
parent | 1b6f8cb1d3c22567bd7aa240a371660593f97555 (diff) | |
download | busybox-w32-1f4d1afe2ce4432d9a5082be1e7d5e9d4629b172.tar.gz busybox-w32-1f4d1afe2ce4432d9a5082be1e7d5e9d4629b172.tar.bz2 busybox-w32-1f4d1afe2ce4432d9a5082be1e7d5e9d4629b172.zip |
Patch from kent robotti to fix a buglet where
# du doesn't_exist
du: doesn't_exist: No such file or directory
0 doesn't_exist
which was on course wrong. I simplified it a bit...
git-svn-id: svn://busybox.net/trunk/busybox@1421 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'du.c')
-rw-r--r-- | du.c | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -60,8 +60,7 @@ static long du(char *filename) | |||
60 | int len; | 60 | int len; |
61 | 61 | ||
62 | if ((lstat(filename, &statbuf)) != 0) { | 62 | if ((lstat(filename, &statbuf)) != 0) { |
63 | printf("du: %s: %s\n", filename, strerror(errno)); | 63 | perror_msg_and_die("%s:", filename); |
64 | return 0; | ||
65 | } | 64 | } |
66 | 65 | ||
67 | du_depth++; | 66 | du_depth++; |
@@ -166,7 +165,7 @@ int du_main(int argc, char **argv) | |||
166 | return status; | 165 | return status; |
167 | } | 166 | } |
168 | 167 | ||
169 | /* $Id: du.c,v 1.30 2000/12/09 17:07:12 andersen Exp $ */ | 168 | /* $Id: du.c,v 1.31 2000/12/11 17:08:21 andersen Exp $ */ |
170 | /* | 169 | /* |
171 | Local Variables: | 170 | Local Variables: |
172 | c-file-style: "linux" | 171 | c-file-style: "linux" |