Pipe is a buffer of fixed size written by one related process and read by another related process. where related process means, parent and child process.
Usage : int pipe(int fildes[2])
creates a pipe and returns two file descriptors, fildes[0] and fildes[1] for reading and writing.
mutual exclusion is handled by operating system, ie only one process at a time can read or write to pipe. If one process is reading or writing on pipe other process will wait.
processes sharing the pipe must have same parent in common and are unaware of each other’s existence
Pipe example
No related posts.
This entry was posted on Friday, July 23rd, 2010 at 2:46 am and is filed under Linux. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.