diff options
author | Pádraig Brady <P@draigBrady.com> | 2009-09-08 10:00:01 +0100 |
---|---|---|
committer | Pádraig Brady <P@draigBrady.com> | 2009-09-08 10:01:45 +0100 |
commit | e8591fd39f70932d40e9a6ddd4e607a89a3162f2 (patch) | |
tree | 184316876536633f36a4385dd20cabd6a893ad50 /tests/tail-2/assert | |
parent | a863644397a66308d60464bace26da857f494f8c (diff) | |
download | coreutils-e8591fd39f70932d40e9a6ddd4e607a89a3162f2.tar.xz |
tests: tail-2/assert: reduce risk of race condition
* tests/tail2/assert: This reverts commit be853120, 25-08-2009,
"tests: tail-2/assert: avoid risk of race condition"
kill -0 doesn't send a signal and so will only confirm that the
background process was forked, which we know already because
we have its pid.
Diffstat (limited to 'tests/tail-2/assert')
-rwxr-xr-x | tests/tail-2/assert | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/tests/tail-2/assert b/tests/tail-2/assert index 623c3684f..416f206a1 100755 --- a/tests/tail-2/assert +++ b/tests/tail-2/assert @@ -42,13 +42,9 @@ tail_pid=$! echo sleeping for 7 seconds... -# Wait for the backgrounded `tail' to start before removing foo. +# Give the backgrounded `tail' a chance to start before removing foo. # Otherwise, without --retry, tail wouldn't try to open `foo' again. -while :; do - env kill -0 $tail_pid && break - echo sleep .1 - sleep .1 -done +sleep 1 rm -f foo sleep 6 |