home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!mcsun!uknet!vision!jim
- From: jim@visionware.co.uk (Jim Musgrave)
- Newsgroups: comp.unix.sysv386
- Subject: Pseudo-tty pairs on SCO V.3.2R4
- Message-ID: <1992Dec15.102805.12050@visionware.co.uk>
- Date: 15 Dec 92 10:28:05 GMT
- Sender: jim@visionware.co.uk (Jim Musgrave)
- Organization: VisionWare Ltd., Leeds, UK
- Lines: 25
-
- Hello everyone,
-
-
- I have a simple application which has two processes. One opens the master side
- of a pseudo-tty and issues a read. The other opens the slave side. The
- master side has the O_NONBLOCK flag set, the read on the master side
- returns 0 when there is no data (EOF?), and 0 when the slave side is closed.
-
- When I issue a select on this file descriptor, it returns implying it is
- readable, when I issue a read, it returns 0. This somewhat defeats the
- object of using select.
-
- How can I tell the slave side has been closed?
-
- (I have the same piece of code running on Interactive 386ix, read and select
- behave as you would expect, thus I can tell when the slave side is no longer
- open and I can determine whether there is data available or not)
-
- Any ideas?
-
- Jim.
- --
- VISIONWARE LTD, 57 Cardigan Lane, LEEDS LS4 2LE, England
- Tel +44 532 788858. Fax +44 532 304676. Email jim@visionware.co.uk
- -------------- "VisionWare: The home of DOS/UNIX/X integration" -------------
-