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...
This commit is contained in:
parent
394cf22668
commit
a293a516ad
@ -60,8 +60,7 @@ static long du(char *filename)
|
|||||||
int len;
|
int len;
|
||||||
|
|
||||||
if ((lstat(filename, &statbuf)) != 0) {
|
if ((lstat(filename, &statbuf)) != 0) {
|
||||||
printf("du: %s: %s\n", filename, strerror(errno));
|
perror_msg_and_die("%s:", filename);
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
du_depth++;
|
du_depth++;
|
||||||
@ -166,7 +165,7 @@ int du_main(int argc, char **argv)
|
|||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* $Id: du.c,v 1.30 2000/12/09 17:07:12 andersen Exp $ */
|
/* $Id: du.c,v 1.31 2000/12/11 17:08:21 andersen Exp $ */
|
||||||
/*
|
/*
|
||||||
Local Variables:
|
Local Variables:
|
||||||
c-file-style: "linux"
|
c-file-style: "linux"
|
||||||
|
5
du.c
5
du.c
@ -60,8 +60,7 @@ static long du(char *filename)
|
|||||||
int len;
|
int len;
|
||||||
|
|
||||||
if ((lstat(filename, &statbuf)) != 0) {
|
if ((lstat(filename, &statbuf)) != 0) {
|
||||||
printf("du: %s: %s\n", filename, strerror(errno));
|
perror_msg_and_die("%s:", filename);
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
du_depth++;
|
du_depth++;
|
||||||
@ -166,7 +165,7 @@ int du_main(int argc, char **argv)
|
|||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* $Id: du.c,v 1.30 2000/12/09 17:07:12 andersen Exp $ */
|
/* $Id: du.c,v 1.31 2000/12/11 17:08:21 andersen Exp $ */
|
||||||
/*
|
/*
|
||||||
Local Variables:
|
Local Variables:
|
||||||
c-file-style: "linux"
|
c-file-style: "linux"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user