What's the system call order of "<" and ">" in the shell (redirection)
<p>I want to know what basical system call happens after you use redirection in terminal.</p>

<p>say, when using &lt;, maybe you used open() but when would you use close()? after whole operation or just after getting the information.</p>

<p>When using >, would you use exec() or folk() to store it? or wait()? and open() would be in front of or behind them?</p>

<p>I just want to know some detail about how to implement them. It gonna be perfect if you can give some example and describe it in detail. If you can tell me where can I check them, it would be OK as well. Thanks!</p>