title: Linux pipe example . ipc pipe creation
body: <p>I was looking through the <code>pipe(2)</code> syscall example in linux, I got this from tldp: <a href="http://tldp.org/LDP/lpg/node11.html#SECTION00722000000000000000" rel="nofollow">http://tldp.org/LDP/lpg/node11.html#SECTION00722000000000000000</a></p>
  
  <p>When we need to close the input of child process we close fd(1) of child - fine, but we should also close the output of the parent i.e. close fd(0) of parent, why should we use else statement here, in this case the parent's fd(0) will close only when the fork fails, am I correct?</p>
  
  <p>I feel there should not be <code>else</code> statement and both the input of child and output of parent should be closed for communication from child to parent correct?</p>