home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.linux
- Path: sparky!uunet!munnari.oz.au!metro!extro.ucc.su.OZ.AU!arumble
- From: arumble@extro.ucc.su.OZ.AU (Anthony Rumble)
- Subject: Re: Termios question: Semantics of VMIN/VTIME on Linux/SunOS ?
- Message-ID: <arumble.711729320@extro.ucc.su.OZ.AU>
- Sender: news@ucc.su.OZ.AU
- Nntp-Posting-Host: extro.ucc.su.oz.au
- Organization: Sydney University Computing Service, Sydney, NSW, Australia
- References: <9207151400@gandalf.moria> <arumble.711530378@extro.ucc.su.OZ.AU> <1992Jul19.201601.13942@klaava.Helsinki.FI>
- Date: Tue, 21 Jul 1992 14:35:20 GMT
- Lines: 27
-
- torvalds@klaava.Helsinki.FI (Linus Benedict Torvalds) writes:
-
- >The way linux does this is (a) wait for at least one character (VMIN > 0
- >and VTIME > 0), (b) read as many characters as possible, with a timeout
- >of max 0.10 seconds between any of the first 5 characters. Thus the
- >read can return:
-
- Errm.. Question.. Can you think of a possible USE of this?
- It dosen't seem quite logical to do it this way, it would be
- much more usefull to return on either 5 chars OR timeout regardless
- on the first character..
-
- >>I was under the impression that this should actually return on
- >>either 5 characters recieved, or sizeof(buffer), or timeout..
-
- >The only thing that I have that explains this all is the SunOS manpage,
- >so I cannot actually guarantee the above behaviour by linux is correct.
- >Could somebody with the POSIX standard available actually check it out?
-
- Well.. Reading my "POSIX programmers guide, I get the impression
- that the correct behaviour is as I stated above, either 5 chars, or sizeof(buffer) or timeout..
-
-
- --
- Anthony Rumble
- aka SmilieZ
- "Anything is possible.. If there is enuf money in it"
-