home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!think.com!barmar
- From: barmar@think.com (Barry Margolin)
- Newsgroups: comp.unix.programmer
- Subject: Re: Named pipes and mknod...
- Date: 6 Nov 1992 17:12:06 GMT
- Organization: Thinking Machines Corporation, Cambridge MA, USA
- Lines: 19
- Message-ID: <1de916INN8o2@early-bird.think.com>
- References: <haley.720956802@husc11>
- NNTP-Posting-Host: telecaster.think.com
- Keywords: named pipe mknod FIFO
-
- In article <haley.720956802@husc11> haley@husc11.harvard.edu (Elizabeth Haley) writes:
- >The man pages suggest how exactly one uses it to make that damned dir
- >entry, which tells me nothing of the mechanism for connecting a driver
- >to it...
-
- Just open it. If two processes open a named pipe (aka a FIFO), anything
- one writes will be read by the other. If you want the driver to be a data
- sink, it should opening it for reading; if it's a data source it should
- open it for writing. Clients should use the opposite mode; named pipes are
- one-way channels.
-
- For more details about using FIFOs, see section 14.5 of "Advanced
- Programming in the UNIX Environment", by W. Richard Stevens (if you thought
- his "Unix Network Programming" was good, you'll love this).
- --
- Barry Margolin
- System Manager, Thinking Machines Corp.
-
- barmar@think.com {uunet,harvard}!think!barmar
-