How can I read keyboard without stopping
The Beach Bum
jfh at rpp386.UUCP
Thu Aug 18 15:05:53 AEST 1988
In article <1267 at ficc.UUCP> peter at ficc.UUCP (Peter da Silva) writes:
>I believe that once upon a time on some system a stat() on a pipe would
>return the number of characters in a pipe. Wouldn't it make sense to
>have stat() on a terminal device return the number of characters available?
>(and a stat() on /dev/mem return memory size, and...)
stat() is implemented by taking chunks of the inode table enty and stuffing
that into a "struct stat" thingy. i believe the number of characters
queued in a pipe was a side effect (read `feature') of the implementation
of pipes, and probably not intentional.
one must remember that under system v, pipes are really just unnamed
files which never grow past a certain size, and who blocks get
juggled as they are written.
--
John F. Haugh II +--------- Cute Chocolate Quote ---------
HASA, "S" Division | "USENET should not be confused with
UUCP: killer!rpp386!jfh | something that matters, like CHOCOLATE"
DOMAIN: jfh at rpp386.uucp | -- apologizes to Dennis O'Connor
More information about the Comp.unix.wizards
mailing list