Path: utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!snorkelwacker!mit-eddie!aryeh From: aryeh@eddie.mit.edu (Aryeh M. Weiss) Newsgroups: comp.unix.xenix Subject: Re: FIORDCHK Message-ID: <1990Jan15.213423.26292@eddie.mit.edu> Date: 15 Jan 90 21:34:23 GMT References: <4587@questar.QUESTAR.MN.ORG> Reply-To: aryeh@eddie.MIT.EDU (Aryeh M. Weiss) Organization: MIT EE/CS Computer Facilities, Cambridge, MA Lines: 16 In article <4587@questar.QUESTAR.MN.ORG> jeff@questar.UUCP (Jeff Holmes) writes: >... > In /usr/include/term.h there is a comment about modification > history dated MAR 18,1988 and the comment... > > ...added XENIX FIORDCHK as alternative to BSD FIONREAD... > > So i tried x = ioctl(0, FIORDCHK, &n) and noticed that "n" > did NOT change but the return value from ioctl was 1 on > a function key press and 0 for anything that returned a single > character. > See the SCO function rdchk(S). Rdchk(S) returns 1 if there is data to be read from the tty. FIORDCHK sounds like it is the ioctl interface to the same function or else rdchk is a wrapper function for this ioctl call. --