]> git.ipfire.org Git - thirdparty/coreutils.git/commit
df: also deduplicate virtual file systems
authorPádraig Brady <P@draigBrady.com>
Sat, 25 Jan 2014 01:14:29 +0000 (01:14 +0000)
committerPádraig Brady <P@draigBrady.com>
Tue, 13 May 2014 22:23:30 +0000 (23:23 +0100)
commit2dc5d044a88fd64e11e35886e78b54a4a9fc2b23
treee1699a1ae50b966640a2af91510694a762a97c3f
parent6b3003a9da29c17324dd3ce395861b07fd7fa27d
df: also deduplicate virtual file systems

* src/df.c (filter_mountlist): Remove the constraint that
a '/' needs to be in the device name for a mount entry to
be considered for deduplication.  Virtual file systems also
have storage associated with them (like tmpfs for example),
and thus need to be deduplicated since they will be shown
in the default df output and subject to --total processing also.
* test/df/skip-duplicates.sh: Add a test to ensure we deduplicate
all entries, even for virtual file systems.  Also avoid possible
length operations on many remote file systems in the initial
check of df operation.  Also avoid the assumption that "/root"
is on the same file system as "/".
* NEWS: Mention the change in behavior.
NEWS
src/df.c
tests/df/skip-duplicates.sh