Comment 1 for bug 498508

Revision history for this message
Alastair Bridgewater (alastair-bridgewater) wrote :

Also reproduced with SBCL 1.0.32.38 on WinXP.

POSIX says that isatty(3) returns 1 if the fd is a tty and 0 otherwise, while MSDN says "nonzero" if the fd is a tty (whether "tty"ness corresponds to being attached to a console handle is another matter). The fd-stream-misc-routine is very obviously using (= 1 (the (member 0 1) (isatty ...))). Perhaps this should be (not (zerop (the integer (isatty ...))))?

Calling interactive-stream-p on a stream for a file on disk works as expected.