Age | Commit message (Collapse) | Author |
|
its heading, even when -P is used with -h or -H.
|
|
This fixes a bug where df would report Size < Used.
(df_readable): Omit last arg; we always round up now.
All callers changed.
|
|
|
|
(long_options, usage, main): Add -B.
(usage): Deprecate --kilobytes, -m, --megabytes.
Document size suffixes.
(print_header, show_dev): Enlarge column widths for trailing "B".
|
|
instead of hard-coding --help and --version descriptions.
|
|
for short options too.''
|
|
Use fputs, not printf.
|
|
[HAVE_RESOLVEPATH], [!HAVE_RESOLVEPATH]: Use malloc, not alloca,
so that these two paths also produce `resolved' in malloc'd storage.
Free that memory when done with it.
|
|
(find_mount_point): No need to strip trailing
slashes before invoking new dir_name.
|
|
the mount directory exists and has the required device number.
Before, e.g., `df /floppy' would mistakenly report on the root
partition if /floppy were not listed in /etc/mtab but / was.
Patch from Eirik Fuller (http://bugs.debian.org/76923).
|
|
|
|
corresponding argument in a `quote (...)' call.
|
|
Use integer arithmetic if it's easy.
Fix bug when converting twos-complement negative values to floating point.
|
|
Round negative numbers correctly.
(show_dev): Round disk usage up and disk free space down.
|
|
Cast undeclared `realpath' to char* to avoid warning.
|
|
|
|
prefixes that are loop file system mount points, since they
yield undesirable output.
|
|
Print the header line only if there is at least one valid argument.
Reported by Andy Longton <alongton@metamark.com>
|
|
(path-concat.h): Include.
(show_point): If HAVE_REALPATH or HAVE_RESOLVEPATH is defined,
find the real absolute path for PATH, and use that to find the
mount point.
(show_point): Prefer non-dummy entries in shortcuts, too.
Disable bogus mount dirs instead of restatting them each time.
|
|
(show_dev): Avoid overflow problems when calculating percent.
Do not display negative percents.
|
|
these and use them instead of `CHAR_MAX + n'.
|
|
New arg NEGATIVE.
(ceil_percent): Now returns double, not int.
Be more careful about adding 1 to a wild value.
(show_dev): Don't filter out wild sizes from the underlying operating
system; instead, show them to the user as faithfully as possible.
|
|
|
|
Use IF_LINT macro instead of #ifdef lint...
|
|
(df_readable): Take ceiling if posix_format.
(ceil_percent): New function.
(show_dev): Take ceiling of percent if posix_format.
Align with POSIX-conforming header if posix_format.
|
|
just warn rather than failing if the table of mounted filesystems
cannot be read.
|
|
via sys2.h.
|
|
Include version-etc.h instead.
(PROGRAM_NAME, AUTHORS): Define.
[long_options]: Add entries for --help and --version.
Remove parse_long_options call.
(main) [getopt switch]: Add a case for each of --help and --version.
|
|
[long_options]: Remove the "help" and "version" entries.
(main): Use parse_long_options, including author name(s).
Remove the show_version and show_help blocks.
|
|
|
|
xargmatch.
|
|
|
|
|
|
let the device path and the file system type share a single (wider)
field if their combined lengths allow it. From Andries Brouwer.
|
|
|
|
Revert to boolean value; the old negative value is
now in show_local_fs.
(show_local_fs): New variable.
(show_dev): New args me_dummy and me_class. Use show_local_fs
and boolean show_all_fs in combination with these new args
to decide whether to show a device.
(show_disk): Pass flags to show_dev.
(show_point): Use a non-dummy mount entry if possible.
(show_all_entries): Pass flags to show_dev.
(main): --local sets show_local_fs now. Ask for file system types if
show_local_fs is nonzero, since ME_REMOTE might need them.
From Paul.
|
|
{"all", no_argument, &show_all_fs, 1},
but rather this form:
{"all", no_argument, NULL, 'a'},
Using the latter, all the option handling in one place: the getopt loop.
|
|
(show_all_fs): If negative, omit non-local filesystems.
All uses of (all_fs != 0) changed to (all_fs > 0).
(long_options, usage, main): Add -l or --local option.
(main): When asking for df of an explicit file name, get all
the mount points, so that we're more likely to find it when
we look it up.
|
|
|
|
|
|
up out of if-block -- code in the else-block depends on it too.
|
|
|
|
replace with new variable output_block_size. All uses changed.
(long_options, usage, main): Add --block-size.
(main, decode_switches): Use new human_block_size function to
initialize output block size consistently with other programs.
(print_header, show_dev): Shrink some columns and expand
others, to squeeze in support for today's larger filesystems.
(print_header): Print output block size using power-of-1024 SI format.
(df_readable): Coalesce last two args into one, for convenience.
All callers changed.
(main): Remove check for portable output format and larger
or human-readable block sizes.
From Paul Eggert.
|
|
|
|
and available columns from 7 to 8.
|
|
|
|
assume the original value corresponding to fsu_bavail was negative.
|
|
last column of `df -i' output. From Andreas Schwab.
|
|
with the rest of the output.
|
|
(show_dev): If a value consists entirely of 1 bits, or is derived
from some other value that consists entirely of 1 bits, report "-".
Check inode and block counts more carefully for plausibility,
to avoid arithmetic overflow when computing percentages.
|