]> git.ipfire.org Git - thirdparty/coreutils.git/commit
tests: fix recent false failure due to a race
authorPádraig Brady <P@draigBrady.com>
Wed, 20 Apr 2016 16:00:47 +0000 (17:00 +0100)
committerPádraig Brady <P@draigBrady.com>
Wed, 20 Apr 2016 16:08:36 +0000 (17:08 +0100)
commit163c70d970ca3e216e24970fc5ebb1b48fdb855e
tree9e42f204c152cba2e6d323d23dc0f24c404dfef0
parent85faa0f4364e20284d19aeddcef5084f436f1aec
tests: fix recent false failure due to a race

* tests/cp/parent-perm-race.sh: This new race introduced in
commit v8.25-5-g632eda5 is quite hard to hit, but is due to
`ls > fifo` doing write()/close()/exit() once `cp` has
open() the source fifo.  Then the subsequent comparison of the
destination file may fail due to the file being missing or empty.
Previously `ls` generated output that was independent of `cp`.
Now we must wait for `cp` to finish before inspecting the
destination file that it wrote.
tests/cp/parent-perm-race.sh