]> git.ipfire.org Git - thirdparty/coreutils.git/commit
Add bulletproofing in case stdin is closed.
authorJim Meyering <jim@meyering.net>
Fri, 12 Aug 2005 08:06:28 +0000 (08:06 +0000)
committerJim Meyering <jim@meyering.net>
Fri, 12 Aug 2005 08:06:28 +0000 (08:06 +0000)
commitf6ab92093a0e199da1fa0085829a2427709ed79d
tree1559d7d5a3146432838d2d0a6bcd2bf9f7c60650
parent75ae174b6a070604d0c799a58879896da4ec5f40
Add bulletproofing in case stdin is closed.

(have_read_stdin): Remove global variable.
(dc_parse_stream): Always use stdin (freopen, if needed) rather
than sometimes using fopen to get a new file descriptor.
Call fclose unconditionally.
(main): Don't close stdin here.  If needed, now it's already done
by dc_parse_stream.
src/dircolors.c