This fixes a segmentation fault on some systems.
exit() will also unwind the atexit() functions. This is bad because if exec*() fails the process is in an inconsistent state.