summaryrefslogtreecommitdiff
path: root/tests/du/files0-from
diff options
context:
space:
mode:
authorPaul Eggert <eggert@CS.UCLA.EDU>2010-07-02 23:41:08 -0700
committerJim Meyering <meyering@redhat.com>2010-07-03 10:28:08 +0200
commitefe53cc72b599979ea292754ecfe8abf7c839d22 (patch)
tree4041993405c58203ccad79280dd9aed419e06ec2 /tests/du/files0-from
parentd27d6d371f3f7ede14b6bde79ddd45307d30fa47 (diff)
downloadcoreutils-efe53cc72b599979ea292754ecfe8abf7c839d22.tar.xz
du: don't miscount duplicate directories or link-count-1 files
* NEWS: Mention this. * src/du.c (hash_all): New static var. (process_file): Use it. (main): Set it. * tests/du/hard-link: Add a couple of test cases to help make sure this bug stays squashed. * tests/du/files0-from: Adjust existing tests to reflect change in semantics with duplicate arguments.
Diffstat (limited to 'tests/du/files0-from')
-rwxr-xr-xtests/du/files0-from8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/du/files0-from b/tests/du/files0-from
index 620246d56..860fc6aad 100755
--- a/tests/du/files0-from
+++ b/tests/du/files0-from
@@ -70,15 +70,15 @@ my @Tests =
{IN=>{f=>"g\0"}}, {AUX=>{g=>''}},
{OUT=>"0\tg\n"}, {OUT_SUBST=>'s/^\d+/0/'} ],
- # two file names, no final NUL
+ # two identical file names, no final NUL
['2', '--files0-from=-', '<',
{IN=>{f=>"g\0g"}}, {AUX=>{g=>''}},
- {OUT=>"0\tg\n0\tg\n"}, {OUT_SUBST=>'s/^\d+/0/'} ],
+ {OUT=>"0\tg\n"}, {OUT_SUBST=>'s/^\d+/0/'} ],
- # two file names, with final NUL
+ # two identical file names, with final NUL
['2a', '--files0-from=-', '<',
{IN=>{f=>"g\0g\0"}}, {AUX=>{g=>''}},
- {OUT=>"0\tg\n0\tg\n"}, {OUT_SUBST=>'s/^\d+/0/'} ],
+ {OUT=>"0\tg\n"}, {OUT_SUBST=>'s/^\d+/0/'} ],
# Ensure that $prog processes FILEs following a zero-length name.
['zero-len', '--files0-from=-', '<',