If i was to create a child process that executes a program, and then send some garbage to the child program through a pipe, resulting in an error, how would i detect an error like this in the parent process?
Would i check to see if the program exited or check an error flag/function like stderror?
This would be developed under unix, if that helps.