LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   implement pipe using C (https://www.linuxquestions.org/questions/programming-9/implement-pipe-using-c-584418/)

chrislam 09-13-2007 10:06 AM

implement pipe using C
 
My assignment is going to create a simple shell and can handle pipe using c
such as the command " cat | cat | more"
I have no idea to do this since I don't know much about the pipe
and I don't know how to let the output of the front process be the input of the following process
let "cat | more" as an example
how to make the STDOUT of cat be the STDIN of more?

wjevans_7d1@yahoo.co 09-13-2007 10:14 AM

The best way to get the most from this classroom assignment is to google for this:
Code:

C pipe
Hope this helps.

osor 09-13-2007 11:50 AM

man 3p pipe
man 3p popen

gauthamk 09-17-2007 09:33 AM

solution for pipe
 
Follow this link u will get some good exemples on pipes.

1)http://www.cs.cf.ac.uk/Dave/C/node23.html

2)http://www.ee.ic.ac.uk/docs/software...sfer/pipe.html


All times are GMT -5. The time now is 01:03 PM.