Path: utzoo!attcan!uunet!datapg!com50!questar!jeff From: jeff@questar.QUESTAR.MN.ORG (Jeff Holmes) Newsgroups: comp.unix.xenix Subject: FIORDCHK Message-ID: <4587@questar.QUESTAR.MN.ORG> Date: 13 Jan 90 06:05:33 GMT Reply-To: jeff@questar.UUCP (Jeff Holmes) Organization: Questar Data Systems, Inc., St. Paul, MN Lines: 41 I was wondering if someone at SCO could field this (or anyone else for that matter). I'm trying to find a portable way to check for function key presses. I know about rdchk(), and I've had a lot of good suggestions from the net, but I'm trying to find the BEST way I can to do this. Which brings me to my question... I have Xenix 386 2.3.2 and while browsing through /usr/include/term.h and /usr/include/sys/ioctl.h I found reference to FIONREAD and FIORDCHK. On a BSD system I would do... int n; ioctl(0, FIONREAD, &n); where n would contain the number of chars to get. 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. Since the use of FIORDCHK is undocumented could someone enlighten me as to the proper use of FIORDCHK? Much thanks, Jeff -- Jeff Holmes DOMAIN: jeff@questar.mn.org Questar Data Systems UUCP: amdahl!bungia!questar!jeff St. Paul, MN 55121 AT&T: +1 612 688 0089