mirror of
https://git.savannah.gnu.org/git/coreutils.git
synced 2026-11-19 03:33:43 +03:00
tee: close "-" file
This is a cleanup to the previous commit v8.23-138-g7ceaf1d. * src/tee.c (tee_files): Do not exempt the "-" file from being closed, as this is no longer stdout but a normal file.
This commit is contained in:
1 parent
7ceaf1d975
commit
19d34d244b
1 file changed
+1
-2
@@ -213,8 +213,7 @@ tee_files (int nfiles, const char **files)
|
||||
|
||||
/* Close the files, but not standard output. */
|
||||
for (i = 1; i <= nfiles; i++)
|
||||
if (!STREQ (files[i], "-")
|
||||
&& descriptors[i] && fclose (descriptors[i]) != 0)
|
||||
if (descriptors[i] && fclose (descriptors[i]) != 0)
|
||||
{
|
||||
error (0, errno, "%s", files[i]);
|
||||
ok = false;
|
||||
|
||||
Reference in new issue
Block a user