bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: isatty() and errno


From: Eric Blake
Subject: Re: isatty() and errno
Date: Tue, 08 Nov 2011 10:12:49 -0700
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.23) Gecko/20110928 Fedora/3.1.15-1.fc14 Lightning/1.0b3pre Mnenhy/0.8.4 Thunderbird/3.1.15

On 11/07/2011 04:52 PM, Eric Blake wrote:
Yuck. Making ptsname_r wrap ptsname() makes it possible to avoid the
isatty() non-errno on Solaris, but exposes a FreeBSD 8.2 bug that
ptsname(-1) doesn't set errno.

Alas, I can't call that a FreeBSD bug; just as with isatty and ttyname[_r], POSIX leaves errno unspecified on ptsname failure. On the other hand, while the POSIX spec of isatty and ttyname both list may fail errors of EBADF and ENOTTY, it didn't list any may fails on ptsname, so maybe that will be corrected in a future revision of POSIX:
http://austingroupbugs.net/view.php?id=503

--
Eric Blake   address@hidden    +1-801-349-2682
Libvirt virtualization library http://libvirt.org



reply via email to

[Prev in Thread] Current Thread [Next in Thread]