Document -k flag.
This commit is contained in:
parent
812bff99b4
commit
1aa67f6900
@ -30,7 +30,7 @@
|
||||
.\" SUCH DAMAGE.
|
||||
.\"
|
||||
.\" @(#)du.1 8.2 (Berkeley) 4/1/94
|
||||
.\" $Id$
|
||||
.\" $Id: du.1,v 1.8 1997/02/22 19:54:52 peter Exp $
|
||||
.\"
|
||||
.Dd April 1, 1994
|
||||
.Dt DU 1
|
||||
@ -42,6 +42,7 @@
|
||||
.Nm du
|
||||
.Op Fl H | Fl L | Fl P
|
||||
.Op Fl a | s | d Ar depth
|
||||
.Op Fl k
|
||||
.Op Fl x
|
||||
.Op Ar file ...
|
||||
.Sh DESCRIPTION
|
||||
@ -55,6 +56,10 @@ the current directory is displayed.
|
||||
The number of blocks are in the same units as that returned by the
|
||||
.Xr stat 2
|
||||
system call, i.e. 512-byte blocks.
|
||||
If the
|
||||
.Fl k
|
||||
flag is specified, the number displayed is the number of 1024-byte
|
||||
blocks.
|
||||
Partial numbers of blocks are rounded up.
|
||||
.Pp
|
||||
The options are as follows:
|
||||
@ -108,12 +113,15 @@ Files having multiple hard links are counted (and displayed) a single
|
||||
time per
|
||||
.Nm du
|
||||
execution.
|
||||
.Sh ENVIRONMENTAL VARIABLES
|
||||
.Sh ENVIRONMENT VARIABLES
|
||||
.Bl -tag -width BLOCKSIZE
|
||||
.It Ev BLOCKSIZE
|
||||
If the environmental variable
|
||||
If the environment variable
|
||||
.Ev BLOCKSIZE
|
||||
is set, the block counts will be displayed in units of that size block.
|
||||
is set, and the
|
||||
.Fl k
|
||||
option is not specified, the block counts will be displayed in units of that
|
||||
size block.
|
||||
.El
|
||||
.Sh SEE ALSO
|
||||
.Xr df 1 ,
|
||||
|
@ -57,7 +57,7 @@ static char sccsid[] = "@(#)du.c 8.5 (Berkeley) 5/4/95";
|
||||
#include <unistd.h>
|
||||
|
||||
int linkchk __P((FTSENT *));
|
||||
void usage __P((void));
|
||||
static void usage __P((void));
|
||||
|
||||
int
|
||||
main(argc, argv)
|
||||
@ -231,17 +231,16 @@ linkchk(p)
|
||||
|
||||
if (nfiles == maxfiles && (files = realloc((char *)files,
|
||||
(u_int)(sizeof(ID) * (maxfiles += 128)))) == NULL)
|
||||
err(1, "");
|
||||
err(1, "can't allocate memory");
|
||||
files[nfiles].inode = ino;
|
||||
files[nfiles].dev = dev;
|
||||
++nfiles;
|
||||
return (0);
|
||||
}
|
||||
|
||||
void
|
||||
static void
|
||||
usage()
|
||||
{
|
||||
|
||||
(void)fprintf(stderr,
|
||||
"usage: du [-H | -L | -P] [-a | -s | -d depth] [-k] [-x] [file ...]\n");
|
||||
exit(1);
|
||||
|
Loading…
x
Reference in New Issue
Block a user