Email list hosting service & mailing list manager

Re: What should tty? do if handed a port that's not even vaguely a tty? Lassi Kortela 10 Aug 2019 21:49 UTC

> Although there's the case when it's handed a port who's file descriptor
> is not valid, which would likely indicate something is terribly wrong,
> or the port was closed.

If these cases can be distinguished reliably, it makes sense to raise an
error for them. Setting "errno = 0" before the call may allow for that.

> Otherwise, I'll have my Chibi Scheme implementation only raise an error
> if it's not handed a port.

I agree this should raise an error. Also if it's a port that
intrinsically doesn't have an fd associated with it (e.g. your earlier
example, a string port).