Date: Sat, 01 Mar 2003 14:19:29 +0200 From: "Eli Zaretskii" Sender: halo1 AT zahav DOT net DOT il To: rich AT phekda DOT freeserve DOT co DOT uk Message-Id: <5567-Sat01Mar2003141929+0200-eliz@elta.co.il> X-Mailer: emacs 21.3.50 (via feedmail 8 I) and Blat ver 1.8.9 CC: djgpp-workers AT delorie DOT com In-reply-to: (rich AT phekda DOT freeserve DOT co DOT uk) Subject: Re: Use _get_dev_info & constants in isatty; add test [PATCH] References: Reply-To: djgpp-workers AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > Date: Thu, 27 Feb 2003 14:40:28 +0000 > From: "Richard Dawe" > > I noticed the other day that isatty uses values rather than using > the constants from . So I fixed that. I also made > it use a _get_dev_info call, rather than duplicating that code. > Using _get_dev_info means that it will detect bad file descriptors > and return errno == EBADF and -1 (as required by POSIX). > I also added a test program. See the patch below. > > OK to commit? Yes, thanks. Please add something to wc204.txi about isatty testing invalid handles and returning EBADF, unlike in previous versions.