Persistent execvp on pipe?
问题 I am working on an assignment for my Operating System class (Posix & C), building a mini-shell, and I don't know how to solve the following problem: My mini-shell has to accept two commands, for example ls | grep a . For that I create a pipe of size two and a child. The child closes all that it has to close and opens all that it has to open (standard/pipe's in & out). It then executes "ls," using execvp. I am sure this works well. After that, the parent shuts and opens inputs and outputs (I