From: Gary Wright Date: 2007-12-08T14:07:12+09:00 Subject: Re: at_exit() Inherited Across fork() On Dec 7, 2007, at 10:47 PM, Joel VanderWerf wrote: > James Gray wrote: >> I guess it just kind of feels like the scripting language should >> be doing something more clever for us here so we don't have to do >> this kind of stuff though. > > I'd rather that ruby mirror the C API, and make it easy to add your > own behavior on top of that. My quick read of suggests that atexit handlers are only called when exit() is called or main() returns. So atexit() handlers are not called before a fork in the C/POSIX world. If Ruby's at_exit() behavior differs from this, I'm not seeing it. Gary Wright