home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / os / linux / 6297 < prev    next >
Encoding:
Text File  |  1992-07-21  |  1.6 KB  |  40 lines

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