From: Pádraig Brady
Date: Tue, 21 Sep 2021 13:01:34 +0000 (+0100)
Subject: tail: fix detection of closed stdout on macOS
X-Git-Tag: v9.0~3
X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=a656db664daca129dba9c481e73eb4e76b9d0009;p=thirdparty%2Fcoreutils.git
tail: fix detection of closed stdout on macOS
* bootstrap.conf: We only need poll on Linux and AIX
where poll is not replaced. Also resinstate dependence
on select so we can use it unconditionally.
* src/tail.c (check_output_alive): Reinstate use of select()
by default as poll was seen to be ineffective for this
application on macOS.
Fixes https://bugs.gnu.org/50714
---
diff --git a/bootstrap.conf b/bootstrap.conf
index bcfc6f0a0c..aef9ec7ded 100644
--- a/bootstrap.conf
+++ b/bootstrap.conf
@@ -194,7 +194,6 @@ gnulib_modules="
physmem
pipe-posix
pipe2
- poll
posix-shell
posixtm
posixver
@@ -230,6 +229,7 @@ gnulib_modules="
save-cwd
savedir
savewd
+ select
selinux-at
setenv
settime
diff --git a/src/tail.c b/src/tail.c
index d2c898adf7..df1b28f07a 100644
--- a/src/tail.c
+++ b/src/tail.c
@@ -28,7 +28,7 @@
#include