[Patches] getpath patch (repost)
Skip Montanaro
skip@mojam.com (Skip Montanaro)
Tue, 23 May 2000 16:40:10 -0500 (CDT)
Me> Maybe call _exit()+stdio flushes where _exit() is available and
Me> abort() otherwise...
Greg> Um... how about a reset here: WHY do you want to avoid the
Greg> atexit() functions?
I was just following the thread with a comment. I suspect you don't want to
call atexit() functions because something seriously bad has happened already
(perhaps a malloc failed) and you don't want to risk screwing things up
worse by executing more Python code at this point. The goal of the abort()
call is to yield a debuggable core dump. If you call a bunch of other
stuff, you risk further masking whatever problem caused the fatal error.
If a core dump isn't desired (that seemed to be the gist of the messages
leading up to my first note), then perhaps _exit() would be a better way to
exit gracefully in the face of a fatal error.
--
Skip Montanaro, skip@mojam.com, http://www.mojam.com/, http://www.musi-cal.com/
"We have become ... the stewards of life's continuity on earth. We did not
ask for this role... We may not be suited to it, but here we are."
- Stephen Jay Gould