Chuck Esterbrook ChuckEsterbrook at
Thu Aug 23 00:41:46 CEST 2001

The 2.1 docs say:


Exit to the system with status n, without calling cleanup handlers, 
flushing stdio buffers, etc. Availability: Unix, Windows.

Note: the standard way to exit is sys.exit(n). _exit() should normally only 
be used in the child process after a fork().

What would be the motivation for a child process of a fork to _exit() 
instead of exit()? e.g., why wouldn't the child wish to cleanup handlers, 
flush stdio buffers, etc.? Does anyone use _exit()?


More information about the Python-list mailing list