3 ms·
What people usually mess up isn't checking the return code from fork, but checking the return code from the call from some exec variant after the fork. As you
by nitwit005 7y ago
What people usually mess up isn't checking the return code from fork, but checking the return code from the call from some exec variant after the fork.
As you have two processes after the fork call, you have to pass exec error results back to the parent process through something like a pipe.