I have used exit() to terminate the process. I do not have any exit handlers registered also I do not care about flushing buffers on exit, so thought of using _exit() as more robust method to terminate process.
The only question is, does _exit() handles closing of all open file descriptors and open sockets gracefully?
The function
exitcalls_exit. From TLPI:The standard page for _exit says this: