From: Martin Castillo Date: Sat, 30 Mar 2019 22:04:06 +0000 (-0700) Subject: maint: tee: use STDIN_FILENO rather than 0 X-Git-Tag: v8.32~92 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ba36d5118facf087221f53ceec9fd9caa7cbbd7a;p=thirdparty%2Fcoreutils.git maint: tee: use STDIN_FILENO rather than 0 * src/tee.c (tee_files): Use the name rather than the value. Addresses https://bugs.gnu.org/35041 --- diff --git a/src/tee.c b/src/tee.c index 4fc2c7b66a..d3aecc7b13 100644 --- a/src/tee.c +++ b/src/tee.c @@ -228,7 +228,7 @@ tee_files (int nfiles, char **files) while (n_outputs) { - bytes_read = read (0, buffer, sizeof buffer); + bytes_read = read (STDIN_FILENO, buffer, sizeof buffer); if (bytes_read < 0 && errno == EINTR) continue; if (bytes_read <= 0)