Fix style issue with not using {}
Raise more specific exceptions in case of pipe() and fork() failure

This will give the user a more descriptive error, for example if there
is not enough memory to fork().